diff --git a/fbchat/__init__.py b/fbchat/__init__.py index 5316c78..6c73aee 100644 --- a/fbchat/__init__.py +++ b/fbchat/__init__.py @@ -15,7 +15,7 @@ from .client import * __copyright__ = 'Copyright 2015 by Taehoon Kim' -__version__ = '0.3.1' +__version__ = '0.4.0' __license__ = 'BSD' __author__ = 'Taehoon Kim; Moreels Pieter-Jan' __email__ = 'carpedm20@gmail.com' diff --git a/fbchat/client.py b/fbchat/client.py index 6576f87..b11c5d8 100644 --- a/fbchat/client.py +++ b/fbchat/client.py @@ -449,9 +449,9 @@ class Client(object): fbid = m['delta']['messageMetadata']['threadKey']['otherUserFbId'] name = None self.on_message(mid, fbid, name, message, m) - else: - print(m) + if self.debug: + print(m) except Exception as e: self.on_message_error(e, m)