aboutsummaryrefslogtreecommitdiffstats
path: root/net/http.lua
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2013-04-12 00:31:05 +0100
committerMatthew Wild <mwild1@gmail.com>2013-04-12 00:31:05 +0100
commit5487d228903f73cb9eba1bc385c7774dfba9a29c (patch)
tree893a3ffefa655c959bd8eeb65c919be4818a4165 /net/http.lua
parentb29f3740f6979ec337ef25a1982dafd6a3c64a38 (diff)
downloadprosody-5487d228903f73cb9eba1bc385c7774dfba9a29c.tar.gz
prosody-5487d228903f73cb9eba1bc385c7774dfba9a29c.zip
net.http: Swap response and request parameters passed to callback (will break some modules)
Diffstat (limited to 'net/http.lua')
-rw-r--r--net/http.lua3
1 files changed, 1 insertions, 2 deletions
diff --git a/net/http.lua b/net/http.lua
index b3bd5a67..4eb4a2ac 100644
--- a/net/http.lua
+++ b/net/http.lua
@@ -76,8 +76,7 @@ local function request_reader(request, data)
if not data then return; end
local function success_cb(r)
if request.callback then
- for k,v in pairs(r) do request[k] = v; end
- request.callback(r.body, r.code, request, r);
+ request.callback(r.body, r.code, r, request);
request.callback = nil;
end
destroy_request(request);