Properly close the sqlite3 connection (#560)

This commit is contained in:
Lonami Exo
2018-01-26 09:59:49 +01:00
parent 5c2dfc17a8
commit 43a3f40527
2 changed files with 30 additions and 13 deletions

View File

@@ -253,6 +253,7 @@ class TelegramBareClient:
# TODO Shall we clear the _exported_sessions, or may be reused?
self._first_request = True # On reconnect it will be first again
self.session.close()
def __del__(self):
self.disconnect()