Backup automatico script del 2026-07-19 07:00
This commit is contained in:
@@ -105,6 +105,15 @@ def send_telegram_message(message: str, chat_ids: Optional[List[str]] = None) ->
|
||||
if not message:
|
||||
return
|
||||
|
||||
try:
|
||||
from telegram_gate import telegram_alerts_enabled
|
||||
except ImportError:
|
||||
telegram_alerts_enabled = lambda: True # type: ignore
|
||||
|
||||
if not telegram_alerts_enabled():
|
||||
LOGGER.info("Telegram sospeso: report speedtest non inviato")
|
||||
return
|
||||
|
||||
bot_token = load_bot_token()
|
||||
if not bot_token:
|
||||
LOGGER.error("Token Telegram mancante (env/file). Messaggio NON inviato.")
|
||||
|
||||
Reference in New Issue
Block a user