diff --git a/zhenxun/builtin_plugins/hooks/auth/auth_ban.py b/zhenxun/builtin_plugins/hooks/auth/auth_ban.py index ed141371..4121d8ff 100644 --- a/zhenxun/builtin_plugins/hooks/auth/auth_ban.py +++ b/zhenxun/builtin_plugins/hooks/auth/auth_ban.py @@ -30,11 +30,7 @@ async def is_ban(user_id: str | None, group_id: str | None) -> int: if not results: return 0 for result in results: - if result.group_id == group_id and ( - result.duration > 0 or result.duration == -1 - ): - return await BanConsole.check_ban_time(user_id, group_id) - if not result.group_id and result.duration == -1: + if result.duration > 0 or result.duration == -1: return await BanConsole.check_ban_time(user_id, group_id) return 0 diff --git a/zhenxun/builtin_plugins/hooks/auth_checker.py b/zhenxun/builtin_plugins/hooks/auth_checker.py index dcf914d8..554ec29e 100644 --- a/zhenxun/builtin_plugins/hooks/auth_checker.py +++ b/zhenxun/builtin_plugins/hooks/auth_checker.py @@ -151,9 +151,9 @@ async def auth( raise PermissionExemption("Matcher插件名称不存在...") plugin, user = await get_plugin_and_user(module, entity.user_id) cost_gold = await get_plugin_cost(bot, user, plugin, session) + bot_filter(session) await asyncio.gather( *[ - bot_filter(session), auth_ban(matcher, bot, session), auth_bot(plugin, bot.self_id), auth_group(plugin, entity, message),