Tes fix perm for channel

Signed-off-by: Yasir Aris M <git@yasirdev.my.id>
This commit is contained in:
Yasir Aris M 2023-10-23 23:23:25 +07:00
parent 49f7ea6835
commit e73a0d2e2b

View file

@ -145,7 +145,7 @@ def adminsOnly(
def wrapper(func):
async def decorator(client, message):
permissions = ""
if message.chat.type != pyrogram.enums.ChatType.SUPERGROUP:
if message.chat.type != pyrogram.enums.ChatType.SUPERGROUP and not ALLOW_CHANNEL:
return await message.reply_text(
"This command can be used in supergroups only.",
)