fixed mute for invited users
This commit is contained in:
parent
322d50b578
commit
f9674a100b
1 changed files with 2 additions and 1 deletions
|
|
@ -50,10 +50,11 @@ async def handle_message(update: Update, context: ContextTypes.DEFAULT_TYPE) ->
|
||||||
# skip if bot
|
# skip if bot
|
||||||
if user.is_bot:
|
if user.is_bot:
|
||||||
continue
|
continue
|
||||||
|
|
||||||
# mute the user
|
# mute the user
|
||||||
await context.bot.restrict_chat_member(
|
await context.bot.restrict_chat_member(
|
||||||
update.message.chat_id,
|
update.message.chat_id,
|
||||||
update.message.from_user.id,
|
update.message.api_kwargs['new_chat_participant']['id'],
|
||||||
restricted_perms
|
restricted_perms
|
||||||
)
|
)
|
||||||
# checks if user is cas banned, do not unmute or give them a captcha
|
# checks if user is cas banned, do not unmute or give them a captcha
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue