mirror of
https://github.com/Nick80835/microbot
synced 2025-09-01 15:05:48 +00:00
clean up imports and fix a couple warnings
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import hashlib
|
||||
|
||||
from telethon import Button, utils
|
||||
from telethon import utils
|
||||
from telethon.tl import functions, types
|
||||
|
||||
|
||||
|
@@ -4,10 +4,8 @@ import glob
|
||||
from concurrent.futures import ThreadPoolExecutor
|
||||
from importlib import import_module, reload
|
||||
from os.path import basename, dirname, isfile
|
||||
from re import escape
|
||||
|
||||
from aiohttp import ClientSession
|
||||
from telethon import events
|
||||
from telethon.tl.types import DocumentAttributeFilename
|
||||
|
||||
from .command_handler import CommandHandler
|
||||
|
@@ -100,10 +100,10 @@ async def dog(event):
|
||||
|
||||
|
||||
@ldr.add_inline_photo("cat", default="cat")
|
||||
async def cat_inline(event):
|
||||
async def cat_inline(_):
|
||||
return [neko["url"] for neko in await neko_atsume(MIMGPARAM)]
|
||||
|
||||
|
||||
@ldr.add_inline_photo("dog", default="dog")
|
||||
async def dog_inline(event):
|
||||
async def dog_inline(_):
|
||||
return [inu["url"] for inu in await inu_atsume(MIMGPARAM)]
|
||||
|
@@ -28,8 +28,7 @@ import io
|
||||
from functools import partial
|
||||
from random import randint, uniform
|
||||
|
||||
from PIL import Image, ImageEnhance, ImageOps
|
||||
from telethon.tl.types import DocumentAttributeFilename
|
||||
from PIL import Image, ImageEnhance
|
||||
|
||||
from ubot.micro_bot import ldr
|
||||
|
||||
|
@@ -1,6 +1,5 @@
|
||||
# SPDX-License-Identifier: GPL-2.0-or-later
|
||||
|
||||
import inspect
|
||||
import io
|
||||
|
||||
from PIL import Image, ImageOps
|
||||
|
@@ -1,6 +1,5 @@
|
||||
# SPDX-License-Identifier: GPL-2.0-or-later
|
||||
|
||||
from random import choice
|
||||
from time import time_ns
|
||||
|
||||
from telethon import Button
|
||||
|
@@ -1,7 +1,6 @@
|
||||
# SPDX-License-Identifier: GPL-2.0-or-later
|
||||
|
||||
from asyncio import sleep
|
||||
from random import choice, randint
|
||||
from random import choice
|
||||
|
||||
from ubot.micro_bot import ldr
|
||||
|
||||
|
@@ -1,8 +1,5 @@
|
||||
# SPDX-License-Identifier: GPL-2.0-or-later
|
||||
|
||||
import io
|
||||
from random import choice, shuffle
|
||||
|
||||
import praw
|
||||
from prawcore import exceptions as redex
|
||||
|
||||
|
@@ -2,7 +2,7 @@
|
||||
|
||||
import io
|
||||
|
||||
from PIL import Image, ImageColor
|
||||
from PIL import Image
|
||||
|
||||
from ubot.micro_bot import ldr
|
||||
|
||||
|
@@ -2,8 +2,6 @@
|
||||
|
||||
from time import time_ns
|
||||
|
||||
from telethon import version
|
||||
|
||||
from ubot.micro_bot import ldr
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user