From 7259746b2be8a87db8bf8c080aa6e75e8a148d8e Mon Sep 17 00:00:00 2001 From: wannaphongcom Date: Fri, 16 Oct 2015 12:51:51 +0700 Subject: [PATCH] Update utils.py --- fbchat/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fbchat/utils.py b/fbchat/utils.py index bd746fb..65c0de1 100644 --- a/fbchat/utils.py +++ b/fbchat/utils.py @@ -15,7 +15,7 @@ def now(): return int(time()*1000) def get_json(text): - return json.loads(re.sub(r"for.*(;;).*;", '', text.decode("unicode-escape").encode('utf-8'), 1)) # have bug !!! AttributeError: 'str' object has no attribute 'decode' + return json.loads(re.sub(r"for.*(.*;.*;.*).*;", '', text.decode("unicode-escape").encode('utf-8'))) # have bug !!! AttributeError: 'str' object has no attribute 'decode' def digit_to_char(digit): if digit < 10: