mirror of
https://github.com/TeamPGM/pyrogram.git
synced 2024-11-30 09:32:49 +00:00
Fix a bug with get_session (#76)
* Fix a bug InputBotInlineMessageID's dc_id being the same with Client's dc_id. Closes #74 --------- Co-authored-by: KurimuzonAkuma <31959970+KurimuzonAkuma@users.noreply.github.com>
This commit is contained in:
parent
31d6a28bbd
commit
0cda4f9c79
@ -36,6 +36,9 @@ async def get_session(client: "pyrogram.Client", dc_id: int) -> Session:
|
|||||||
|
|
||||||
await session.start()
|
await session.start()
|
||||||
|
|
||||||
|
if dc_id == await client.storage.dc_id():
|
||||||
|
return session
|
||||||
|
|
||||||
for _ in range(3):
|
for _ in range(3):
|
||||||
exported_auth = await client.invoke(
|
exported_auth = await client.invoke(
|
||||||
raw.functions.auth.ExportAuthorization(
|
raw.functions.auth.ExportAuthorization(
|
||||||
|
Loading…
Reference in New Issue
Block a user