aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar kwzrd <[email protected]>2020-03-22 14:26:18 +0100
committerGravatar kwzrd <[email protected]>2020-03-22 14:26:18 +0100
commit1b82d409053e30495d61f18c7989cf6b6e4c3836 (patch)
tree791418102e070a5afebbfdba0dd51678efa9a471
parentDeseasonify: respect autostart env var (diff)
Deseasonify: add property to check daemon status
-rw-r--r--bot/branding.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/bot/branding.py b/bot/branding.py
index 39c3b52c..0b5c7b7e 100644
--- a/bot/branding.py
+++ b/bot/branding.py
@@ -108,6 +108,11 @@ class BrandingManager(commands.Cog):
else:
self.daemon = None
+ @property
+ def _daemon_running(self) -> bool:
+ """True if the daemon is currently active, False otherwise."""
+ return self.daemon is not None and not self.daemon.done()
+
async def _daemon_func(self) -> None:
"""
Manage all automated behaviour of the BrandingManager cog.