added convertion hikka- chats

pull/40/head
Who? 2024-12-16 22:09:24 +07:00 committed by GitHub
parent 4fef698b1a
commit b7e024b782
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 4 additions and 0 deletions

View File

@ -754,6 +754,10 @@ async def asset_channel(
):
return client._channels_cache[title]["peer"], False
# legacy heroku / hikka chats conversion to heroku
if title.startswith("hikka-"):
title = title.replace("hikka-", "heroku-")
async for d in client.iter_dialogs():
if d.title == title:
client._channels_cache[title] = {"peer": d.entity, "exp": int(time.time())}