-
-
Notifications
You must be signed in to change notification settings - Fork 39.9k
Open
Labels
bugSomething isn't workingSomething isn't workingstaleMarked as stale due to inactivityMarked as stale due to inactivity
Description
In src/telegram/bot-message-context.ts (line ~405):
const senderId = msg.from?.id ? String(msg.from.id) : "";
Problem:
• When a channel posts to a group → msg.from?.id = fake system ID (all channels appear as one sender)
• When a user posts to a group → msg.from?.id = real ID (correct)
When a message comes from a channel, there is no sender/user — the source is the channel itself with msg.sender_chat.id.
Solution:
const senderId = msg.sender_chat?.id ?? msg.from?.id ? String(msg.sender_chat?.id ?? msg.from?.id) : "";
This correctly handles both cases:
• Channel message → use sender_chat.id (real source)
• User message → use from.id (real sender)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingstaleMarked as stale due to inactivityMarked as stale due to inactivity