mirror of
https://github.com/whyour/qinglong.git
synced 2026-12-01 01:39:52 +08:00
修复goCqHttpBotToken中存在&字符导致认证失败的问题 (#993)
修改goCqHttpBot鉴权方式,调整为使用Header模式
This commit is contained in:
1 parent
89e08953cb
commit
a809b89bb0
1 file changed
+2
-1
@@ -91,11 +91,12 @@ export default class NotificationService {
|
||||
const { goCqHttpBotQq, goCqHttpBotToken, goCqHttpBotUrl } = this.params;
|
||||
const res: any = await got
|
||||
.post(
|
||||
`${goCqHttpBotUrl}?access_token=${goCqHttpBotToken}&${goCqHttpBotQq}`,
|
||||
`${goCqHttpBotUrl}?${goCqHttpBotQq}`,
|
||||
{
|
||||
timeout: this.timeout,
|
||||
retry: 0,
|
||||
json: { message: `${this.title}\n${this.content}` },
|
||||
headers: { 'Authorization': 'Bearer '+goCqHttpBotToken },
|
||||
},
|
||||
)
|
||||
.json();
|
||||
|
||||
Reference in new issue
Block a user