加入bot,自动注入内容,在项目启动完成之后,给每个插件注入bot
This commit is contained in:
@@ -46,7 +46,6 @@ class GameTaskPlugin(MessagePluginInterface):
|
||||
def __init__(self):
|
||||
super().__init__()
|
||||
self.LOG = logger
|
||||
self.bot: WechatAPIClient = None
|
||||
async_job.at_times(["14:43"])(self.run_random_task_assignment)
|
||||
|
||||
def initialize(self, context: Dict[str, Any]) -> bool:
|
||||
@@ -117,7 +116,6 @@ class GameTaskPlugin(MessagePluginInterface):
|
||||
gbm: GroupBotManager = message.get("gbm")
|
||||
all_contacts = message.get("all_contacts", {})
|
||||
|
||||
self.bot: WechatAPIClient = message.get("bot")
|
||||
self.LOG.debug(f"插件执行: {self.name}:{content}")
|
||||
|
||||
# 检查权限
|
||||
|
||||
Reference in New Issue
Block a user