diff options
Diffstat (limited to 'misc')
-rw-r--r-- | misc/freeswitch/scripts/http_request.lua | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/misc/freeswitch/scripts/http_request.lua b/misc/freeswitch/scripts/http_request.lua index 8acdcb6..1d6f791 100644 --- a/misc/freeswitch/scripts/http_request.lua +++ b/misc/freeswitch/scripts/http_request.lua @@ -28,4 +28,9 @@ if user and password then end local success, result, response_headers = http.request{url = url, headers = headers }; -log:debug('HTTP_REQUEST - url: ', url, ', auth: ', tostring(headers.Authorization ~= nil), ', result: ', result); + +if success then + log:debug('HTTP_REQUEST - url: ', url, ', auth: ', tostring(headers.Authorization ~= nil), ', result: ', result); +else + log:notice('HTTP_REQUEST - url: ', url, ', auth: ', tostring(headers.Authorization ~= nil), ', result: ', result); +end |