From 97e73b853878d1d5919e99d109046e90c37e2b92 Mon Sep 17 00:00:00 2001 From: JACK <69492163+Jack-tg@users.noreply.github.com> Date: Mon, 21 Sep 2020 19:45:23 +0530 Subject: [PATCH 1/5] Update requirements.txt --- requirements.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/requirements.txt b/requirements.txt index 1af829c3a..5351baee6 100644 --- a/requirements.txt +++ b/requirements.txt @@ -4,8 +4,8 @@ git+git://github.com/google/chatbase-python.git hachoir numpy Pillow -https://github.com/pyrogram/pyrogram/archive/asyncio-dev.zip requests tgcrypto sqlalchemy psycopg2-binary +Pyrogram==1.0.6 From c14a81615388ab01f67b34752d8352c803862dd0 Mon Sep 17 00:00:00 2001 From: JACK <69492163+Jack-tg@users.noreply.github.com> Date: Mon, 21 Sep 2020 19:47:04 +0530 Subject: [PATCH 2/5] Update chat_base.py --- helper_funcs/chat_base.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/helper_funcs/chat_base.py b/helper_funcs/chat_base.py index 6a2ae2159..b7cda04c0 100644 --- a/helper_funcs/chat_base.py +++ b/helper_funcs/chat_base.py @@ -19,7 +19,7 @@ # the Strings used for this "thing" from translation import Translation -from pyrogram import Client, Filters +from pyrogram import Client, filters # the Telegram trackings from chatbase import Message From 125b10ff214addcf6122c5d65d9c6b4464f81df2 Mon Sep 17 00:00:00 2001 From: JACK <69492163+Jack-tg@users.noreply.github.com> Date: Mon, 21 Sep 2020 19:48:09 +0530 Subject: [PATCH 3/5] Update custom_thumbnail.py --- plugins/custom_thumbnail.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/plugins/custom_thumbnail.py b/plugins/custom_thumbnail.py index ca16f4741..a245c5507 100644 --- a/plugins/custom_thumbnail.py +++ b/plugins/custom_thumbnail.py @@ -28,7 +28,7 @@ from helper_funcs.chat_base import TRChatBase import database.database as sql -@pyrogram.Client.on_message(pyrogram.Filters.command(["generatecustomthumbnail"])) +@pyrogram.Client.on_message(pyrogram.filters.command(["generatecustomthumbnail"])) async def generate_custom_thumbnail(bot, update): if update.from_user.id in Config.BANNED_USERS: await update.reply_text("You are B A N N E D") @@ -80,7 +80,7 @@ async def generate_custom_thumbnail(bot, update): ) -@pyrogram.Client.on_message(pyrogram.Filters.photo) +@pyrogram.Client.on_message(pyrogram.filters.photo) async def save_photo(bot, update): if update.from_user.id in Config.BANNED_USERS: await bot.delete_messages( @@ -116,7 +116,7 @@ async def save_photo(bot, update): ) -@pyrogram.Client.on_message(pyrogram.Filters.command(["deletethumbnail"])) +@pyrogram.Client.on_message(pyrogram.filters.command(["deletethumbnail"])) async def delete_thumbnail(bot, update): if update.from_user.id in Config.BANNED_USERS: await bot.delete_messages( From ff677bdb20fb144c21438f011fcf3584e2302aeb Mon Sep 17 00:00:00 2001 From: JACK <69492163+Jack-tg@users.noreply.github.com> Date: Mon, 21 Sep 2020 19:48:40 +0530 Subject: [PATCH 4/5] Update help_text.py --- plugins/help_text.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/plugins/help_text.py b/plugins/help_text.py index 6684ab59e..83f40a68b 100644 --- a/plugins/help_text.py +++ b/plugins/help_text.py @@ -31,7 +31,7 @@ def GetExpiryDate(chat_id): return expires_at -@pyrogram.Client.on_message(pyrogram.Filters.command(["help", "about"])) +@pyrogram.Client.on_message(pyrogram.filters.command(["help", "about"])) async def help_user(bot, update): # logger.info(update) TRChatBase(update.from_user.id, update.text, "/help") @@ -43,7 +43,7 @@ async def help_user(bot, update): reply_to_message_id=update.message_id ) -@pyrogram.Client.on_message(pyrogram.Filters.command(["start"])) +@pyrogram.Client.on_message(pyrogram.filters.command(["start"])) async def start(bot, update): # logger.info(update) TRChatBase(update.from_user.id, update.text, "/start") @@ -54,7 +54,7 @@ async def start(bot, update): ) -@pyrogram.Client.on_message(pyrogram.Filters.command(["upgrade"])) +@pyrogram.Client.on_message(pyrogram.filters.command(["upgrade"])) async def upgrade(bot, update): # logger.info(update) TRChatBase(update.from_user.id, update.text, "/upgrade") From 7a5e752dd8f1a557426801f4994b82cdef23ec83 Mon Sep 17 00:00:00 2001 From: JACK <69492163+Jack-tg@users.noreply.github.com> Date: Mon, 21 Sep 2020 19:49:05 +0530 Subject: [PATCH 5/5] Update rename_file.py --- plugins/rename_file.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/rename_file.py b/plugins/rename_file.py index 4bcb8b00e..8803708c4 100644 --- a/plugins/rename_file.py +++ b/plugins/rename_file.py @@ -22,7 +22,7 @@ import pyrogram logging.getLogger("pyrogram").setLevel(logging.WARNING) -from pyrogram import Client, Filters +from pyrogram import Client, filters from helper_funcs.chat_base import TRChatBase from helper_funcs.display_progress import progress_for_pyrogram @@ -34,7 +34,7 @@ from database.database import * -@pyrogram.Client.on_message(pyrogram.Filters.command(["rename"])) +@pyrogram.Client.on_message(pyrogram.filters.command(["rename"])) async def rename_doc(bot, update): if update.from_user.id in Config.BANNED_USERS: await update.reply_text("You are B A N N E D")