Use postData field in PUT, PATCH requests too

The HAR spec isn't really clear on whether this should be the case,
but Google Chrome does this, so I think we should too.
This commit is contained in:
Shadab Zafar 2016-08-12 01:31:33 +05:30
parent 15c488225f
commit 4f1fb43dcc
1 changed files with 1 additions and 1 deletions

View File

@ -135,7 +135,7 @@ def response(flow):
else:
entry["response"]["content"]["text"] = flow.response.content
if flow.request.method == "POST":
if flow.request.method in ["POST", "PUT", "PATCH"]:
entry["request"]["postData"] = {
"mimeType": flow.request.headers.get("Content-Type", "").split(";")[0],
"text": flow.request.content,