Spaces:
Paused
Paused
Delete plugins/help_text.py
Browse files- plugins/help_text.py +0 -50
plugins/help_text.py
DELETED
|
@@ -1,50 +0,0 @@
|
|
| 1 |
-
|
| 2 |
-
# (c) mohdsabahat
|
| 3 |
-
|
| 4 |
-
#Logging
|
| 5 |
-
import logging
|
| 6 |
-
logging.basicConfig(level=logging.DEBUG,
|
| 7 |
-
format='%(asctime)s - %(name)s - %(levelname)s - %(message)s')
|
| 8 |
-
|
| 9 |
-
logger = logging.getLogger(__name__)
|
| 10 |
-
|
| 11 |
-
import os
|
| 12 |
-
import pyrogram
|
| 13 |
-
from chat import Chat
|
| 14 |
-
from config import Config
|
| 15 |
-
logging.getLogger('pyrogram').setLevel(logging.WARNING)
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
@pyrogram.Client.on_message(pyrogram.filters.command(['help']))
|
| 19 |
-
async def help_user(bot, update):
|
| 20 |
-
|
| 21 |
-
if str(update.from_user.id) in Config.ALLOWED_USERS:
|
| 22 |
-
await bot.send_message(
|
| 23 |
-
update.chat.id,
|
| 24 |
-
Chat.HELP_TEXT,
|
| 25 |
-
reply_to_message_id = update.id
|
| 26 |
-
)
|
| 27 |
-
|
| 28 |
-
else:
|
| 29 |
-
|
| 30 |
-
await bot.send_message(
|
| 31 |
-
update.chat.id,
|
| 32 |
-
Chat.NO_AUTH_USER,
|
| 33 |
-
reply_to_message_id = update.id
|
| 34 |
-
)
|
| 35 |
-
|
| 36 |
-
@pyrogram.Client.on_message(pyrogram.filters.command(['start']))
|
| 37 |
-
async def start(bot, update):
|
| 38 |
-
|
| 39 |
-
if str(update.from_user.id) not in Config.ALLOWED_USERS:
|
| 40 |
-
return await bot.send_message(
|
| 41 |
-
update.chat.id,
|
| 42 |
-
Chat.NO_AUTH_USER,
|
| 43 |
-
reply_to_message_id = update.id
|
| 44 |
-
)
|
| 45 |
-
|
| 46 |
-
await bot.send_message(
|
| 47 |
-
chat_id = update.chat.id,
|
| 48 |
-
text = Chat.START_TEXT,
|
| 49 |
-
reply_to_message_id = update.id
|
| 50 |
-
)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|