mirror of
https://github.com/LLOneBot/LLOneBot.git
synced 2024-11-22 01:56:33 +00:00
fix
This commit is contained in:
parent
8b57ebd7de
commit
b3b8f9cd72
@ -341,7 +341,7 @@ function onLoad() {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
/*registerReceiveHook<FriendRequestNotify>(ReceiveCmdS.FRIEND_REQUEST, async (payload) => {
|
registerReceiveHook<FriendRequestNotify>(ReceiveCmdS.FRIEND_REQUEST, async (payload) => {
|
||||||
for (const req of payload.data.buddyReqs) {
|
for (const req of payload.data.buddyReqs) {
|
||||||
if (!!req.isInitiator || (req.isDecide && req.reqType !== BuddyReqType.KMEINITIATORWAITPEERCONFIRM)) {
|
if (!!req.isInitiator || (req.isDecide && req.reqType !== BuddyReqType.KMEINITIATORWAITPEERCONFIRM)) {
|
||||||
continue
|
continue
|
||||||
@ -349,7 +349,7 @@ function onLoad() {
|
|||||||
let userId = 0
|
let userId = 0
|
||||||
try {
|
try {
|
||||||
const requesterUin = await NTQQUserApi.getUinByUid(req.friendUid)
|
const requesterUin = await NTQQUserApi.getUinByUid(req.friendUid)
|
||||||
userId = parseInt(requesterUin!)
|
userId = parseInt(requesterUin)
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
log('获取加好友者QQ号失败', e)
|
log('获取加好友者QQ号失败', e)
|
||||||
}
|
}
|
||||||
@ -362,7 +362,7 @@ function onLoad() {
|
|||||||
)
|
)
|
||||||
postOb11Event(friendRequestEvent)
|
postOb11Event(friendRequestEvent)
|
||||||
}
|
}
|
||||||
})*/
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
let startTime = 0 // 毫秒
|
let startTime = 0 // 毫秒
|
||||||
|
@ -98,12 +98,12 @@ export class NTQQGroupApi {
|
|||||||
)
|
)
|
||||||
return notifies
|
return notifies
|
||||||
} else {
|
} else {
|
||||||
return await invoke<GroupNotifies>({
|
return (await invoke<GroupNotifies>({
|
||||||
methodName: NTMethod.GET_GROUP_NOTICE,
|
methodName: NTMethod.GET_GROUP_NOTICE,
|
||||||
cbCmd: ReceiveCmdS.GROUP_NOTIFY,
|
cbCmd: ReceiveCmdS.GROUP_NOTIFY,
|
||||||
afterFirstCmd: false,
|
afterFirstCmd: false,
|
||||||
args: [{ doubt: false, startSeq: '', number: num }, null],
|
args: [{ doubt: false, startSeq: '', number: num }, null],
|
||||||
})
|
})).notifies
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -11,7 +11,7 @@ function generateMsgId() {
|
|||||||
const buffer = Buffer.alloc(8)
|
const buffer = Buffer.alloc(8)
|
||||||
buffer.writeUInt32BE(timestamp, 0)
|
buffer.writeUInt32BE(timestamp, 0)
|
||||||
buffer.writeUInt32BE(random, 4)
|
buffer.writeUInt32BE(random, 4)
|
||||||
const msgId = BigInt("0x" + buffer.toString('hex')).toString()
|
const msgId = BigInt('0x' + buffer.toString('hex')).toString()
|
||||||
return msgId
|
return msgId
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user