mirror of
https://github.com/langbot-app/LangBot.git
synced 2026-06-02 03:55:55 +00:00
fix: update config in wxoa
This commit is contained in:
@@ -93,16 +93,15 @@ class OfficialAccountAdapter(adapter.MessagePlatformAdapter):
|
||||
if missing_keys:
|
||||
raise ParamNotEnoughError("微信公众号缺少相关配置项,请查看文档或联系管理员")
|
||||
|
||||
# 模式1为15s内回复,模式2为超过15s回复
|
||||
|
||||
if self.config['Mode'] == 1:
|
||||
if self.config['Mode'] == "drop":
|
||||
self.bot = OAClient(
|
||||
token=config['token'],
|
||||
EncodingAESKey=config['EncodingAESKey'],
|
||||
Appsecret=config['AppSecret'],
|
||||
AppID=config['AppID'],
|
||||
)
|
||||
if self.config['Mode'] == 2:
|
||||
if self.config['Mode'] == "passive":
|
||||
self.bot = OAClientForLongerResponse(
|
||||
token=config['token'],
|
||||
EncodingAESKey=config['EncodingAESKey'],
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
"EncodingAESKey":"",
|
||||
"AppID":"",
|
||||
"AppSecret":"",
|
||||
"Mode":1,
|
||||
"Mode":"drop",
|
||||
"host": "0.0.0.0",
|
||||
"port": 2287
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user