diff --git a/config.sample.yaml b/config.sample.yaml index 071c20d..24bc6c0 100644 --- a/config.sample.yaml +++ b/config.sample.yaml @@ -1,3 +1,2 @@ telegram_token: "" telegram_channel: "@canal_o_grupo" -telegram_chat_id: 0 diff --git a/managers/telegram_manager.py b/managers/telegram_manager.py index 8f29c5a..1bf0f4e 100644 --- a/managers/telegram_manager.py +++ b/managers/telegram_manager.py @@ -29,9 +29,8 @@ FAVORITES_FILE = "favorites.json" class TelegramManager: def __init__(self): self.logger = logging.getLogger(__name__) - token, channel, chat_id = self.get_config() + token, channel = self.get_config() self._channel = channel - self._chat_id = chat_id # Use ApplicationBuilder to create the bot application with increased timeouts self._application = telegram.ext.ApplicationBuilder() \ .token(token) \ @@ -61,8 +60,7 @@ class TelegramManager: config = yaml.safe_load(file) token = config['telegram_token'] telegram_channel = config['telegram_channel'] - telegram_chat_id = config['telegram_chat_id'] - return token, telegram_channel, telegram_chat_id + return token, telegram_channel def escape_html(self, text): return html.escape(str(text))