diff options
| author | 2022-04-16 17:14:31 +0100 | |
|---|---|---|
| committer | 2022-04-20 22:14:51 +0100 | |
| commit | a196ec9d49c8da3bcca0f6a84b06b383797e6af7 (patch) | |
| tree | 00619449cacf3e5cc969669b7914425b0b710211 | |
| parent | Use site api over redis for thread bumps (diff) | |
Only call unarchive threads if there are threads to send
| -rw-r--r-- | bot/exts/utils/thread_bumper.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/bot/exts/utils/thread_bumper.py b/bot/exts/utils/thread_bumper.py index 6bd9efc08..8d0ebdf1c 100644 --- a/bot/exts/utils/thread_bumper.py +++ b/bot/exts/utils/thread_bumper.py @@ -71,7 +71,8 @@ class ThreadBumper(commands.Cog): if thread.archived: threads_to_maybe_bump.append(thread) - await self.unarchive_threads_not_manually_archived(threads_to_maybe_bump) + if threads_to_maybe_bump: + await self.unarchive_threads_not_manually_archived(threads_to_maybe_bump) @commands.group(name="bump") async def thread_bump_group(self, ctx: commands.Context) -> None: |