aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Chris Lovering <[email protected]>2025-02-08 20:10:21 +0000
committerGravatar Chris Lovering <[email protected]>2025-02-08 20:10:21 +0000
commitbe44163e142fa3f534cb33820540a571ea889d0d (patch)
tree8c0623c01382b06e7ea534fdb6e793fa0c1267fd
parentMerge pull request #3254 from python-discord/fix-help-cog (diff)
Ignore both archived and locked posts when archiving idle
For some reason a thread with .closed=True was getting past this if statement. See https://python-discord.sentry.io/issues/6281905188 and the value for post in the stack frame
-rw-r--r--bot/exts/help_channels/_channel.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/bot/exts/help_channels/_channel.py b/bot/exts/help_channels/_channel.py
index 4e65d9379..cd1a0ac58 100644
--- a/bot/exts/help_channels/_channel.py
+++ b/bot/exts/help_channels/_channel.py
@@ -198,7 +198,7 @@ async def maybe_archive_idle_post(post_id: int, scheduler: scheduling.Scheduler)
log.trace(f"Not closing missing post #{post} ({post.id}).")
return
- if post.locked:
+ if post.archived or post.locked:
log.trace(f"Not closing already closed post #{post} ({post.id}).")
return