diff options
author | Matthew Wild <mwild1@gmail.com> | 2016-07-27 14:08:32 +0100 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2016-07-27 14:08:32 +0100 |
commit | 3a8e8da3dfd5635cbf67c9d9d1c768e07a53cee3 (patch) | |
tree | a1568a41de954c6611e3334860644f96a2866121 /net/http.lua | |
parent | 6cf7ca7a863b099ee8382a474a8ca53519c05b36 (diff) | |
parent | f78f6631d3694a1ed5c0827629bd40e34e60bef9 (diff) | |
download | prosody-3a8e8da3dfd5635cbf67c9d9d1c768e07a53cee3.tar.gz prosody-3a8e8da3dfd5635cbf67c9d9d1c768e07a53cee3.zip |
Merge 0.10 -> trunk
Diffstat (limited to 'net/http.lua')
-rw-r--r-- | net/http.lua | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/net/http.lua b/net/http.lua index 669fa9a5..5c1f2058 100644 --- a/net/http.lua +++ b/net/http.lua @@ -117,7 +117,7 @@ end local function handleerr(err) log("error", "Traceback[http]: %s", traceback(tostring(err), 2)); end local function log_if_failed(id, ret, ...) if not ret then - log("error", "Request %s: error in callback: %s", id, tostring((...))); + log("error", "Request '%s': error in callback: %s", id, tostring((...))); end return ...; end @@ -172,7 +172,7 @@ local function request(u, ex, callback) end end - log("debug", "Making %s %s request %s to %s", req.scheme, method or "GET", req.id, (ex and ex.suppress_url and host_header) or u); + log("debug", "Making %s %s request '%s' to %s", req.scheme:upper(), method or "GET", req.id, (ex and ex.suppress_url and host_header) or u); -- Attach to request object req.method, req.headers, req.body = method, headers, body; @@ -197,7 +197,7 @@ local function request(u, ex, callback) req.write = function (...) return req.handler:write(...); end req.callback = function (content, code, request, response) - log("debug", "request %s: Calling callback, status %s", req.id, code or "---"); + log("debug", "Request '%s': Calling callback, status %s", req.id, code or "---"); return log_if_failed(req.id, xpcall(function () return callback(content, code, request, response) end, handleerr)); end req.reader = request_reader; |