From 7d96a64b482e0f3f1b928638bff46ea7adaff359 Mon Sep 17 00:00:00 2001 From: Yasir Aris M Date: Tue, 30 Jul 2024 08:30:18 +0700 Subject: [PATCH] Fixx --- misskaty/plugins/dev.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/misskaty/plugins/dev.py b/misskaty/plugins/dev.py index edbc71ea..6023a1c2 100644 --- a/misskaty/plugins/dev.py +++ b/misskaty/plugins/dev.py @@ -358,7 +358,7 @@ async def shell_cmd(self: Client, ctx: Message, strings): [ InlineKeyboardButton( text=strings("cl_btn"), - callback_data=f"close#{ctx.from_user.id}", + callback_data=f"close#{ctx.from_user.id if ctx.from_user else self.me.id}", ) ] ] @@ -376,7 +376,7 @@ async def shell_cmd(self: Client, ctx: Message, strings): [ InlineKeyboardButton( text=strings("cl_btn"), - callback_data=f"close#{ctx.from_user.id}", + callback_data=f"close#{ctx.from_user.id if ctx.from_user else self.me.id}", ) ] ] @@ -504,7 +504,7 @@ async def cmd_eval(self: Client, ctx: Message, strings) -> Optional[str]: [ InlineKeyboardButton( text=strings("cl_btn"), - callback_data=f"close#{ctx.from_user.id}", + callback_data=f"close#{ctx.from_user.id if ctx.from_user else self.me.id}", ) ] ] @@ -522,7 +522,7 @@ async def cmd_eval(self: Client, ctx: Message, strings) -> Optional[str]: [ InlineKeyboardButton( text=strings("cl_btn"), - callback_data=f"close#{ctx.from_user.id}", + callback_data=f"close#{ctx.from_user.id if ctx.from_user else self.me.id}", ) ] ]