mirror of
https://github.com/yasirarism/MissKatyPyro.git
synced 2026-01-05 03:34:51 +00:00
FOrget things
This commit is contained in:
parent
375be9672c
commit
3e297573df
2 changed files with 4 additions and 1 deletions
|
|
@ -12,6 +12,7 @@ import aiohttp
|
|||
from datetime import datetime
|
||||
from shutil import disk_usage
|
||||
from time import time
|
||||
from database.users_chats_db import db
|
||||
from inspect import getfullargspec
|
||||
from typing import Any, Optional, Tuple
|
||||
|
||||
|
|
@ -313,6 +314,8 @@ async def update_restart(self: Client, ctx: Message, strings) -> "Message":
|
|||
async def updtebot(client, update, users, chats):
|
||||
if isinstance(update, UpdateBotStopped):
|
||||
user = users[update.user_id]
|
||||
if update.stopped and await db.is_user_exist(user.id)::
|
||||
await db.delete_user(user.id)
|
||||
await client.send_msg(LOG_CHANNEL, f"<a href='tg://user?id={user.id}'>{user.first_name}</a> (<code>{user.id}</code>) " f"{'BLOCKED' if update.stopped else 'UNBLOCKED'} the bot at " f"{datetime.fromtimestamp(update.date)}")
|
||||
|
||||
async def aexec(code, c, m):
|
||||
|
|
|
|||
|
|
@ -119,7 +119,7 @@ async def ceksub(self: Client, ctx: Message, strings):
|
|||
@use_chat_lang()
|
||||
async def convertsrt(self: Client, ctx: Message, strings):
|
||||
reply = ctx.reply_to_message
|
||||
if replied and replied.document and (replied.document.file_name and replied.document.file_name.endswith(".vtt") or replied.document.file_name.endswith(".ass")):
|
||||
if reply and reply.document and (reply.document.file_name and reply.document.file_name.endswith(".vtt") or reply.document.file_name.endswith(".ass")):
|
||||
msg = await ctx.reply_msg(strings("convert_str"), quote=True)
|
||||
if not os.path.exists("downloads"):
|
||||
os.makedirs("downloads")
|
||||
|
|
|
|||
Loading…
Reference in a new issue