Files
SnowLuma/packages
DrSmoothl 9a678442e9 fix(msg): unswap markRead import aliases in Bridge
The `markGroupMsgAsRead` / `markPrivateMsgAsRead` Bridge methods were
calling the wrong underlying implementations because the alias names
on the import line were swapped:

  - `markPrivateMessageRead as markGroupMsgAsRead_` meant calling
    `bridge.markGroupMsgAsRead(groupId, …)` actually fired the c2c
    (private) read-report wire shape with `groupId` shoved into the
    `userId` slot — the server then resolved a uid for what was
    really a groupId and posted to the wrong route.

  - `markGroupMessageRead as markPrivateMsgAsRead_` was the mirror:
    `bridge.markPrivateMsgAsRead(userId, …)` fired the group read-
    report shape with `userId` in the `groupUin` field.

Realigned to the intended pairing. The underlying implementations
in `actions/group-message.ts` are already covered by
`tests/actions/group-message.test.ts` (asserts both hit
`SsoReadedReport` with their proper wire shapes); they pass
unchanged because they always tested the action-layer functions
directly, never the Bridge facade where the swap lived.

Caught while planning the #6 Api-on-ctx refactor — preserving the
swap into the new MessageApi would have carried the bug forward.
2026-05-20 22:08:38 +08:00
..
2026-05-20 14:21:03 +08:00
2026-05-20 14:21:03 +08:00