update
This commit is contained in:
1 parent
7ca0f86e51
commit
7bd7ac6214
1 file changed
+1
-1
@@ -17,7 +17,7 @@
|
||||
// You can optional change the response headers at the same time by using $done({body: modifiedBody, headers: modifiedHeaders}); only change the response headers is not allowed for script-response-body. The modifiedHeaders can be copied and modified from $response.headers, please do not change the content length, type and encoding field.
|
||||
// Response status can also be optional changed by using $done({body: modifiedBody, headers: modifiedHeaders, status: modifiedStatus}), the modifiedStatus should be like "HTTP/1.1 200 OK"
|
||||
|
||||
var body = $request.body;
|
||||
var body = $request.headers;
|
||||
var obj = JSON.parse(body);
|
||||
|
||||
obj['X-Real-IP'] = "219.133.168.5";
|
||||
|
||||
Reference in new issue
Block a user