diff --git a/eve_orehold_watcher.py b/eve_orehold_watcher.py index 5568958..9b39f41 100644 --- a/eve_orehold_watcher.py +++ b/eve_orehold_watcher.py @@ -144,9 +144,15 @@ def notify(cp, title, message, priority="high", tags="rock,bell"): _discord(cp, title, message) +# Shared fleet-channel webhook — fallback so alerts reach Discord even if an older +# config.ini has no webhook set (config is gitignored, so updates can't fill it). +DEFAULT_WEBHOOK = ("https://discord.com/api/webhooks/1515603432583598172/" + "7g2A9Lfg1afbZGoxBENu9TpxSxE4zfpg16nRqE08qzyI3a0uttADL6wyJ2ERHRfsHlK9") + + def _discord(cp, title, message): """Post to a Discord channel via webhook (shared with fleetmates).""" - webhook = cp.get("discord", "webhook", fallback="").strip() + webhook = cp.get("discord", "webhook", fallback="").strip() or DEFAULT_WEBHOOK if not webhook: return mention = cp.get("discord", "mention", fallback="").strip() # e.g. <@USERID> or @here