Merge "Fix default value for a header"

This commit is contained in:
Jenkins
2013-10-09 05:06:39 +00:00
committed by Gerrit Code Review
+1 -1
View File
@@ -248,7 +248,7 @@ class HTTPClient(object):
resp, body_iter = self._http_request(url, method, **kwargs)
if 'application/json' in resp.getheader('content-type', None):
if 'application/json' in resp.getheader('content-type', ''):
body = ''.join([chunk for chunk in body_iter])
try:
body = json.loads(body)