Skip to content

fix(groups): keep LID digits out of group panel names - #526

Merged
setkyar merged 1 commit into
mainfrom
fix/group-panel-lid-names
Nov 23, 2026
Merged

setkyar merged 1 commit into
mainfrom
fix/group-panel-lid-names

Conversation

@setkyar

@setkyar setkyar commented Nov 23, 2026

Copy link
Copy Markdown
Contributor

Fixes #382.

Problem

The group info panel only masked unnamed LID members at the very end of its name fallback chain. Migration 034 backfilled messages.sender_name with the bare LID digits for unmapped senders, so that value won first. The panel showed a member's raw WhatsApp ID digits instead of "WhatsApp user (ID …XXXX)".

Fix

  • Export getSafeIdentityName from @wateaminbox/shared. It is the guard the contact profile already uses.
  • Run every stored name in the panel's fallback chain through it. A name that only restates the LID falls through to the masked label.
  • Real names on LID members are kept.

Tests

  • group-sync.integration.test.ts: a stored name that restates the LID digits no longer bypasses the mask.
  • contact.test.ts: the guard rejects names that only restate an LID and keeps real names (and every name on a phone JID).
  • Rebased on main. Typecheck, biome and both suites pass on a fresh Postgres 18.

Release

No migration. worker: skip. The fix is in the API, not the web bundle.

The group info panel masked unnamed LID members only at the end of its
name fallback chain. Migration 034 backfilled messages.sender_name with
the bare LID local part for unmapped senders, so that value won first
and the panel showed the opaque identity digits.

Export getSafeIdentityName, the guard the contact profile already uses,
and run every stored name in the panel chain through it, so a name that
only restates the LID falls through to the masked label. Real names on
LID members are kept.

Fixes #382
@setkyar
setkyar force-pushed the fix/group-panel-lid-names branch from f9aea25 to 1aa6c25 Compare November 23, 2026 18:17
@setkyar
setkyar merged commit 62cf9cb into main Nov 23, 2026
9 checks passed
@setkyar
setkyar deleted the fix/group-panel-lid-names branch November 23, 2026 18:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Detail Bug] Groups: Group info panel shows raw LID digits for some participants due to unguarded sender_name fallback

1 participant