From b6e07dd35ec8e4b4566a1759f08620c8f364a774 Mon Sep 17 00:00:00 2001 From: Chris Caron Date: Sat, 24 Jun 2023 16:33:48 -0400 Subject: [PATCH] Bugfix: Telegram attachments respect topic thread (#893) --- apprise/plugins/NotifyTelegram.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/apprise/plugins/NotifyTelegram.py b/apprise/plugins/NotifyTelegram.py index 11311e18..3abbd6e9 100644 --- a/apprise/plugins/NotifyTelegram.py +++ b/apprise/plugins/NotifyTelegram.py @@ -471,11 +471,14 @@ class NotifyTelegram(NotifyBase): # content can arrive together. self.throttle() + payload = {'chat_id': chat_id} + if self.topic: + payload['message_thread_id'] = self.topic + try: with open(path, 'rb') as f: # Configure file payload (for upload) files = {key: (file_name, f)} - payload = {'chat_id': chat_id} self.logger.debug( 'Telegram attachment POST URL: %s (cert_verify=%r)' % (