From 7f596342d143dc6b8fc34b4c61b547177e8b2de9 Mon Sep 17 00:00:00 2001 From: "S. Co1" Date: Mon, 25 Nov 2019 18:40:27 -0500 Subject: Default seasons to not send announcements --- bot/seasons/season.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/bot/seasons/season.py b/bot/seasons/season.py index 3546fda6..e7b7a69c 100644 --- a/bot/seasons/season.py +++ b/bot/seasons/season.py @@ -79,6 +79,7 @@ class SeasonBase: start_date: Optional[str] = None end_date: Optional[str] = None + should_announce: bool = False colour: Optional[int] = None icon: Tuple[str, ...] = ("/logos/logo_full/logo_full.png",) @@ -268,11 +269,11 @@ class SeasonBase: """ Announces a change in season in the announcement channel. - It will skip the announcement if the current active season is the "evergreen" default season. + Auto-announcement is configured by the `should_announce` `SeasonBase` attribute """ - # Don't actually announce if reverting to normal season - if self.name in ("evergreen", "wildcard", "halloween"): - log.debug(f"Season Changed: {self.name}") + # Short circuit if the season had disabled automatic announcements + if not self.should_announce: + log.debug(f"Season changed without announcement: {self.name}") return guild = bot.get_guild(Client.guild) -- cgit v1.2.3