mirror of
https://github.com/PaiGramTeam/PaiGram.git
synced 2024-11-29 11:03:16 +00:00
🐛 修复洪水修饰器导致角色卡片命令无法调用的问题
This commit is contained in:
parent
65f9f03479
commit
6e5a803896
@ -39,7 +39,7 @@ class PlayerCards(Plugin, BasePlugin):
|
||||
@handler(CommandHandler, command="player_card", block=False)
|
||||
@handler(MessageHandler, filters=filters.Regex("^角色卡片查询(.*)"), block=False)
|
||||
@restricts(filters.ChatType.GROUPS, restricts_time=20, try_delete_message=True)
|
||||
@restricts()
|
||||
@restricts(filters.ChatType.PRIVATE)
|
||||
@error_callable
|
||||
async def player_cards(self, update: Update, context: CallbackContext) -> None:
|
||||
user = update.effective_user
|
||||
@ -116,8 +116,8 @@ class PlayerCards(Plugin, BasePlugin):
|
||||
await message.reply_photo(pnd_data, filename=f"player_card_{uid}_{character_name}.png")
|
||||
|
||||
@handler(CallbackQueryHandler, pattern=r"^get_player_card\|", block=False)
|
||||
@restricts(filters.ChatType.GROUPS, restricts_time=20, try_delete_message=True)
|
||||
@restricts()
|
||||
@restricts(filters.ChatType.GROUPS, restricts_time=3)
|
||||
@restricts(filters.ChatType.PRIVATE)
|
||||
async def get_player_cards(self, update: Update, _: CallbackContext) -> None:
|
||||
callback_query = update.callback_query
|
||||
user = callback_query.from_user
|
||||
|
Loading…
Reference in New Issue
Block a user