Skip to content

Commit

Permalink
Merge branch 'main' of https://github.com/NapNeko/NapCatQQ
Browse files Browse the repository at this point in the history
  • Loading branch information
MliKiowa committed Aug 14, 2024
2 parents acad07a + 51bbb48 commit 8645a41
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/onebot/action/user/GetCookies.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ export class GetCookies extends BaseAction<Payload, Response> {
const cookiesObject = await NTQQUserApi.getCookies(payload.domain);
//把获取到的cookiesObject转换成 k=v; 格式字符串拼接在一起
const cookies = Object.entries(cookiesObject).map(([key, value]) => `${key}=${value}`).join('; ');
const bkn = NTQQWebApi.getBknFromCookie(cookiesObject);
const bkn = cookiesObject?.skey ? NTQQWebApi.getBknFromCookie(cookiesObject) : '';
return { cookies, bkn };
}
}
2 changes: 1 addition & 1 deletion src/onebot/helper/data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ export class OB11Constructor {
messagePostFormat: string = obcore.configLoader.configData.messagePostFormat
): Promise<OB11Message | undefined> {
if (msg.senderUin == "0" || msg.senderUin == "") return;
if (msg.peerUin == "0" || msg.peerUin) return;
if (msg.peerUin == "0" || msg.peerUin == "") return;
//跳过空消息
const NTQQGroupApi = core.apis.GroupApi;
const NTQQUserApi = core.apis.UserApi;
Expand Down

0 comments on commit 8645a41

Please sign in to comment.