aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDevendra2015-06-05 10:43:40 +0530
committerDevendra2015-06-05 10:43:40 +0530
commit8e6cb39a795f8f5790d7cba7a761787ce3214801 (patch)
treea4e48e960041dc692fbad1dd7c5d2037354c5091
parent86f7235829ca2ff29705f80714fc3548b27097ab (diff)
downloadpubnub-python-8e6cb39a795f8f5790d7cba7a761787ce3214801.tar.bz2
fixing issue where grant dint work on python 3
-rw-r--r--Pubnub.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/Pubnub.py b/Pubnub.py
index 7fcc38e..e837471 100644
--- a/Pubnub.py
+++ b/Pubnub.py
@@ -332,11 +332,12 @@ class PubnubBase(object):
def _pam_sign(self, msg):
- return urlsafe_b64encode(hmac.new(
+ sign = urlsafe_b64encode(hmac.new(
self.secret_key.encode("utf-8"),
msg.encode("utf-8"),
sha256
).digest())
+ return quote(sign, safe="")
def set_u(self, u=False):
self.u = u