Skip to content

Commit

Permalink
Add orinal response field to asyncio response status
Browse files Browse the repository at this point in the history
  • Loading branch information
anovikov1984 committed Mar 20, 2017
1 parent 8c079cf commit 037a682
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion pubnub/pubnub_asyncio.py
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,8 @@ def _request_helper(self, options_func, cancellation_event):
origin=request_url.hostname,
uuid=uuid,
auth_key=auth_key,
client_request=None
client_request=None,
client_response=response
)

if body is not None and len(body) > 0:
Expand Down
3 changes: 2 additions & 1 deletion pubnub/structures.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,13 +66,14 @@ def __init__(self, headers, pn_config):


class ResponseInfo(object):
def __init__(self, status_code, tls_enabled, origin, uuid, auth_key, client_request):
def __init__(self, status_code, tls_enabled, origin, uuid, auth_key, client_request, client_response=None):
self.status_code = status_code
self.tls_enabled = tls_enabled
self.origin = origin
self.uuid = uuid
self.auth_key = auth_key
self.client_request = client_request
self.client_response = client_response


class Envelope(object):
Expand Down

0 comments on commit 037a682

Please sign in to comment.