diff --git a/astrbot/core/platform/sources/telegram/tg_adapter.py b/astrbot/core/platform/sources/telegram/tg_adapter.py index fba96a6fe..2852df70e 100644 --- a/astrbot/core/platform/sources/telegram/tg_adapter.py +++ b/astrbot/core/platform/sources/telegram/tg_adapter.py @@ -176,8 +176,8 @@ class TelegramPlatformAdapter(Platform): command_dict[cmd_name] = description - commands_a = sorted(command_dict.keys()) - commands = [BotCommand(cmd, command_dict[cmd]) for cmd in commands_a] + sorted_commands = sorted(command_dict.keys()) + commands = [BotCommand(cmd, command_dict[cmd]) for cmd in sorted_commands] return commands async def start(self, update: Update, context: ContextTypes.DEFAULT_TYPE):