From 5016e204cd2026b11aef79e3a3aa10907aa9e739 Mon Sep 17 00:00:00 2001 From: spag Date: Wed, 6 Feb 2013 18:50:50 +0100 Subject: increase verbosity when request fails --- misc/freeswitch/scripts/http_request.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'misc/freeswitch/scripts/http_request.lua') diff --git a/misc/freeswitch/scripts/http_request.lua b/misc/freeswitch/scripts/http_request.lua index 1d6f791..a74b4d8 100644 --- a/misc/freeswitch/scripts/http_request.lua +++ b/misc/freeswitch/scripts/http_request.lua @@ -29,7 +29,7 @@ end local success, result, response_headers = http.request{url = url, headers = headers }; -if success then +if success and tostring(result) == '200' 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); -- cgit v1.2.3