mirror of
https://github.com/jxxghp/MoviePilot.git
synced 2026-05-13 23:16:45 +00:00
* fix(telegram): handle caption messages in group chat @mention detection Telegram media messages (photos, videos, etc.) store their text in `message.caption` and mention entities in `message.caption_entities`, not `message.text` / `message.entities`. The previous code only checked `message.text`, so commands and @mentions sent with media were silently skipped with "No text..." in the debug log. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * fix(telegram): use correct entity field pairing and UTF-16 offsets for mention detection - Explicitly pair message.entities with text messages and caption_entities with media messages, avoiding false fallthrough on empty entity lists - Decode mention text via UTF-16-LE encoding to respect Telegram's UTF-16 based offset/length values, fixing incorrect slicing when emojis are present Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> --------- Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>