From ac880a863c8872a643508943de6b625176c5baa6 Mon Sep 17 00:00:00 2001 From: Marco Loewe Date: Tue, 14 Nov 2023 12:45:22 +0100 Subject: [PATCH] Fixed on_ready when update was pending --- bot.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bot.py b/bot.py index ded2759..2ce6e20 100644 --- a/bot.py +++ b/bot.py @@ -26,8 +26,8 @@ async def on_ready(): await tree.sync(guild=discord.Object(id='745287426402156555')) print(f'Logged in as {client.user}') print('------') - if data['update'] & data['update'] == 'pending': - client.get_channel(1173561093579362305).send('Update done') + if data['update'] == 'pending': + await client.get_channel(1173561093579362305).send('Update done') write_json('update', 'none') @@ -59,4 +59,4 @@ def write_json(key: str, value: any): with open('config.json', 'w') as f: f.write(json.dumps(data)) -client.run(data['token']) \ No newline at end of file +client.run(data['token'])