This commit is contained in:
2026-03-10 23:52:19 +00:00
parent 592521026a
commit 87958ba09c
2 changed files with 10 additions and 1 deletions
+5
View File
@@ -1,5 +1,10 @@
# Changelog
## [2.1.2] - 2026-03-10
### Fixed
- Prevented AttributeError in modqueue watcher by checking for the 'title' attribute before accessing it. This ensures safe handling of Comment objects that do not have a 'title'.
## [2.1.1] - 2026-03-10
### Fixed
+5 -1
View File
@@ -293,7 +293,11 @@ class ModReplyBot:
flair = (submission.link_flair_text or '').strip().lower()
else:
flair = ''
title = submission.title.strip()
# Only access title if it's a Submission
if hasattr(submission, 'title'):
title = submission.title.strip()
else:
title = ''
import re
title_tags = re.findall(r'\[(.*?)\]', title)
title_tags_lower = [t.strip().lower() for t in title_tags]