diff --git a/basethon/json_converter.py b/basethon/json_converter.py index a192ee6..a70b35f 100644 --- a/basethon/json_converter.py +++ b/basethon/json_converter.py @@ -39,7 +39,9 @@ class JsonConverter(BaseSession): ss._dc_id = client.session.dc_id # type: ignore ss._port = client.session.port # type: ignore string_session = ss.save() - del ss, client + asyncio.run(client.disconnect()) # type: ignore + del client + del ss loop.close() json_data["proxy"] = self.__proxy json_data["string_session"] = string_session