Skip to content

Commit

Permalink
chore: aiocqhttp添加默认access-token参数
Browse files Browse the repository at this point in the history
  • Loading branch information
RockChinQ committed Mar 13, 2024
1 parent afb3fb4 commit be06150
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pkg/platform/sources/aiocqhttp.py
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ async def shutdown_trigger_placeholder():

self.ap = ap

if "access-token" in config and config["access-token"]:
if "access-token" in config:
self.bot = aiocqhttp.CQHttp(access_token=config["access-token"])
del self.config["access-token"]
else:
Expand Down
3 changes: 2 additions & 1 deletion templates/platform.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@
"adapter": "aiocqhttp",
"enable": false,
"host": "0.0.0.0",
"port": 8080
"port": 8080,
"access-token": ""
},
{
"adapter": "qq-botpy",
Expand Down

0 comments on commit be06150

Please sign in to comment.