fix(onebot): correct private message history (#256)
Use the C2C roam cursor and canonical NT sequence for bidirectional history. Persist direction-aware recall tombstones so recalled messages cannot reappear.
This commit is contained in:
37 files changed
+1853
-242
No files matched your search
@@ -780,6 +780,8 @@ describe('parseMsgPush Event0x210 subType=139 (self-recall direction)', () => {
|
||||
expect(event.kind).toBe('friend_recall');
|
||||
expect(event.userUin).toBe(77777);
|
||||
expect(event.msgSeq).toBe(4242);
|
||||
expect(event.clientSeq).toBe(4242);
|
||||
expect(event.recalledBySelf).toBe(false);
|
||||
});
|
||||
|
||||
it('subType 139 picks toUid as the peer (we recalled our msg sent to friend)', () => {
|
||||
@@ -791,6 +793,7 @@ describe('parseMsgPush Event0x210 subType=139 (self-recall direction)', () => {
|
||||
|
||||
expect(event.kind).toBe('friend_recall');
|
||||
expect(event.userUin).toBe(77777); // resolved from toUid (the friend), not fromUid (us)
|
||||
expect(event.recalledBySelf).toBe(true);
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
Reference in new issue
Block a user