Skip to content
Snippets Groups Projects
Commit 0394374f authored by Tamas Gal's avatar Tamas Gal :speech_balloon:
Browse files

Fix context manager

parent 6f0b6e5c
No related branches found
No related tags found
No related merge requests found
......@@ -151,7 +151,8 @@ class Client(object):
self._update_subscriptions()
def __enter__(self):
self._connect()
if not self.socket:
self._connect()
return self
def __exit__(self, exit_type, value, traceback):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment