fix(userbot): add missing safone.py imports, apply ruff --unsafe-fixes

- Add missing aiohttp, PIL, BytesIO imports to safone.py (F821 runtime bugs)
- Apply ruff --unsafe-fixes (27 fixes): ternary operators, .get() patterns,
  contextlib.suppress, enumerate(), collapsible if/else, remove .keys()
This commit is contained in:
2026-06-19 15:27:12 +02:00
parent c905bbd039
commit 20bce5b31c
20 changed files with 29 additions and 57 deletions
+1 -1
View File
@@ -59,7 +59,7 @@ class HelpNavigator:
text += f'Help Page No: {self.current_page}/{self.total_pages}\n\n'
for module_name in page_modules:
commands = modules_help[module_name]
text += f'<b>• {module_name.title()}:</b> {", ".join([f"<code>{prefix + cmd_name.split()[0]}</code>" for cmd_name in commands.keys()])}\n'
text += f'<b>• {module_name.title()}:</b> {", ".join([f"<code>{prefix + cmd_name.split()[0]}</code>" for cmd_name in commands])}\n'
text += f'\n<b>The number of modules in the userbot: {len(modules_help)}</b>'
await message.edit(text, disable_web_page_preview=True)