From a6a45f4b84c75b9dfed9e2df748b3b9fae3cc4ad Mon Sep 17 00:00:00 2001 From: Xin <5097752+imfing@users.noreply.github.com> Date: Mon, 5 Jan 2026 23:54:35 +0000 Subject: [PATCH] fix(whatsapp): populate senderE164 for direct chats to enable owner commands (#247) --- src/web/inbound.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/web/inbound.ts b/src/web/inbound.ts index fe147e2fe..2043b0d39 100644 --- a/src/web/inbound.ts +++ b/src/web/inbound.ts @@ -144,10 +144,14 @@ export async function monitorWebInbox(options: { continue; const group = isJidGroup(remoteJid); const participantJid = msg.key?.participant ?? undefined; - const senderE164 = participantJid ? jidToE164(participantJid) : null; const from = group ? remoteJid : jidToE164(remoteJid); // Skip if we still can't resolve an id to key conversation if (!from) continue; + const senderE164 = group + ? participantJid + ? jidToE164(participantJid) + : null + : from; let groupSubject: string | undefined; let groupParticipants: string[] | undefined; if (group) {