Commit c2844b26 authored by ash's avatar ash

Always log non-200 responses from the GitLab API.

parent 90b9e113
......@@ -56,7 +56,11 @@ class GitlabNet
end
http.start {|http| http.request(request) }.tap do |resp|
$logger.debug { "Received response #{resp.code} => #{resp.body}" }
if resp.code == "200"
$logger.debug { "Received response #{resp.code} => <#{resp.body}>." }
else
$logger.error { "API call <GET #{url}> failed: #{resp.code} => <#{resp.body}>." }
end
end
end
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment