@@ -176,14 +176,17 @@ export namespace OB11Entities {
176176 guildId : ''
177177 }
178178 try {
179- const { replayMsgSeq, replyMsgTime } = replyElement
180- const record = msg . records . find ( msgRecord => msgRecord . msgId === replyElement . sourceMsgIdInRecords )
179+ const { replayMsgSeq : replyMsgSeq , replyMsgTime } = replyElement
180+ let record = msg . records . find ( msgRecord => msgRecord . msgId === replyElement . sourceMsgIdInRecords )
181+ const { msgList } = await ctx . ntMsgApi . getMsgsBySeqAndCount ( peer , replyMsgSeq , 1 , true , true )
182+ if ( ! record ) {
183+ record = msgList . find ( msg => msg . msgSeq === replyMsgSeq && msg . msgTime === replyMsgTime )
184+ }
181185 const senderUid = replyElement . senderUidStr || record ?. senderUid
182186 if ( ! record || ! replyMsgTime || ! senderUid ) {
183187 ctx . logger . error ( '找不到回复消息' , replyElement )
184188 continue
185189 }
186- const { msgList } = await ctx . ntMsgApi . getMsgsBySeqAndCount ( peer , replayMsgSeq , 1 , true , true )
187190
188191 let replyMsg : RawMessage | undefined
189192 if ( record . msgRandom !== '0' ) {
@@ -640,9 +643,12 @@ export namespace OB11Entities {
640643 msg : RawMessage ,
641644 shortId : number
642645 ) : Promise < OB11FriendRecallNoticeEvent | OB11GroupRecallNoticeEvent | undefined > {
643- const revokeElement = msg . elements [ 0 ] . grayTipElement ?. revokeElement
646+ const revokeElement = msg . elements [ 0 ] . grayTipElement ?. revokeElement !
644647 if ( msg . chatType === ChatType . Group ) {
645- const operator = await ctx . ntGroupApi . getGroupMember ( msg . peerUid , revokeElement ! . operatorUid )
648+ const operator = await ctx . ntGroupApi . getGroupMember ( msg . peerUid , revokeElement . operatorUid )
649+ if ( msg . senderUin === '0' || ! msg . senderUin ) {
650+ msg . senderUin = await ctx . ntUserApi . getUinByUid ( revokeElement . origMsgSenderUid ! )
651+ }
646652 return new OB11GroupRecallNoticeEvent (
647653 parseInt ( msg . peerUid ) ,
648654 parseInt ( msg . senderUin ! ) ,
0 commit comments