Py3 fixes
This commit is contained in:
@@ -102,7 +102,7 @@ def fireEvent(name, *args, **kwargs):
|
||||
# Fire
|
||||
result = e(*args, **kwargs)
|
||||
|
||||
result_keys = result.keys()
|
||||
result_keys = list(result.keys())
|
||||
result_keys.sort(key = natsortKey)
|
||||
|
||||
if options['single'] and not options['merge']:
|
||||
|
||||
@@ -231,7 +231,11 @@ class Plugin(object):
|
||||
|
||||
status_code = response.status_code
|
||||
if response.status_code == requests.codes.ok:
|
||||
data = response if stream else response.content
|
||||
if stream:
|
||||
data = response
|
||||
else:
|
||||
data = response.content
|
||||
data = data.decode(response.encoding)
|
||||
else:
|
||||
response.raise_for_status()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user