测试auth动态化
This commit is contained in:
@@ -8,7 +8,6 @@ from typing import Callable, Dict, Any, Tuple
|
||||
|
||||
from db.stats_db import StatsDBOperator
|
||||
from db.connection import DBConnectionManager
|
||||
from wechat_ipad import WechatAPIClient
|
||||
|
||||
|
||||
def plugin_stats_decorator(plugin_name: str) -> Callable:
|
||||
|
||||
@@ -206,15 +206,14 @@ def plugin_points_cost(points: int, description: str = None, feature_key: str =
|
||||
return False, "没有权限"
|
||||
|
||||
# 检查是否开启了积分获取功能
|
||||
if (GroupBotManager.get_group_permission(roomid,
|
||||
Feature.SIGNIN) == PermissionStatus.DISABLED
|
||||
and GroupBotManager.get_group_permission(
|
||||
roomid, Feature.TASK_GAME) == PermissionStatus.DISABLED):
|
||||
return await func(self, message)
|
||||
# if (GroupBotManager.get_group_permission(roomid,
|
||||
# Feature.SIGNIN) == PermissionStatus.DISABLED
|
||||
# and GroupBotManager.get_group_permission(
|
||||
# roomid, Feature.TASK_GAME) == PermissionStatus.DISABLED):
|
||||
# return await func(self, message)
|
||||
|
||||
# 获取消息信息
|
||||
sender = message.get("sender", "")
|
||||
roomid = message.get("roomid", "")
|
||||
|
||||
bot: WechatAPIClient = message.get("bot")
|
||||
revoke: MessageAutoRevoke = message.get("revoke")
|
||||
|
||||
Reference in New Issue
Block a user