From 7ceece808fa7fe4d032c4cfd26f9a0b9fc4e66fe Mon Sep 17 00:00:00 2001 From: levina <82658782+levina-lab@users.noreply.github.com> Date: Tue, 2 Nov 2021 16:40:37 +0700 Subject: [PATCH] fixes `coroutine` object has no attribute `id` --- main.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/main.py b/main.py index 6ee8a3b..3b8df66 100644 --- a/main.py +++ b/main.py @@ -7,8 +7,8 @@ from pytgcalls import idle def all_info(bot, user): global BOT_ID, USERBOT_ID - getme = bot.get_me() - getme1 = user.get_me() + getme = await bot.get_me() + getme1 = await user.get_me() BOT_ID = getme.id USERBOT_ID = getme1.id @@ -19,7 +19,7 @@ async def mulai_bot(): print("[INFO]: STARTING PYTGCALLS CLIENT") await call_py.start() print("[INFO]: GENERATING CLIENT PROFILE") - await all_info(bot, user) + all_info(bot, user) await idle() print("[INFO]: STOPPING BOT") await bot.stop()