I understand that posts in archived topic cannot be liked or reacted. On that basis, how come this post can be liked (in a sense that you can press the heart, although it throws a ‘That reaction was created too long ago. It can no longer be modified or removed.’ error, which also is not correct).
Actually, this applies to other posts in that topic. Though it seems posts with likes/recations cannot be liked at all, but those with none can be, albeit with that error thrown.
This inconsistent behaviour makes me think this should be in Contribute > Bug , perhaps?
Moin
April 1, 2026, 6:15am
2
I think it’s because of the reactions plugin. I cannot do the same in safe mode . And I remember accidentally adding a reaction to an archived post back when Jammy was the community moderator. Since my reaction was quite inappropriate, he removed it for me, and I think something was added to prevent that in the future. But I am not sure, and finding that in our chat will take very long.
1 Like
Alright. So in safe mode , the button cannot be pressed at all. I guess it should be hidden then on archived topics?
Moin
April 1, 2026, 6:24am
4
Looks like my problem occurred on posts that already had a like.
our conversation
For this one, did you add the reaction before it was archived?
For me, it seems to block both adding and removing a reaction when archived (as expected)
I can still add to posts in that topic
Ah yes. It says you can't, but you can
And no removal
Hmm
I unarchived it and tidied up the stray Reactions
I'll pop a report in
I'm getting some oddities in my repro for this archiving + reactions test
On my test site, the reactions menu doesn't show up
Only the
I can repro at my playground
Hmm
Create topic
Add reply
Archive
As test user, visit topic and attempt to react to a post
Now It doesn't work there neither
I tried on my Basic hosted site and that also does not work
When the test user creates the reply and I archive and react without a reload, adding the reaction works. But not after the refresh
Try liking the post as user2 before archiving and then react with as 3 afterwards
Yes, I can repro with that
1 Like
Thanks @NateDhaliwal & @Moin , looks like reactions had some wrong logic when it came to handling archived topics.
main ← fix/reactions-archived-topic-like-button
merged 02:38PM - 01 Apr 26 UTC
When a post in an archived topic has no existing likes, the backend omits the li… ke entry from `actions_summary` (no count, no `can_act`, no `acted`), making `likeAction` null on the frontend.
Core's like button handles this correctly (renders as disabled), but the reactions plugin — which replaces core's like button — had guards that checked `likeAction && !(canToggle || can_undo)`. When `likeAction` was null, the guard was bypassed, allowing clicks that triggered a 403 from the backend with a misleading "too long ago" error message.
Posts with existing likes were unaffected since `likeAction` existed with `canToggle: false`, and the guard worked as intended.
This commit:
- Flips the `toggleFromButton` guard from `likeAction && ...` to `!likeAction || ...` so null likeAction blocks the interaction
- Reorders the `toggle()` condition to check `likeAction?.canToggle` first, preventing reactions via the emoji picker
- Adds an early return in `pointerOver` when `!likeAction?.canToggle` to prevent the reaction picker from opening on hover
- Adds optional chaining in the picker's `reactionInfo` getter to fix a TypeError crash on `post.likeAction.canToggle` when null
- Uses the server error message in `_extractErrors` when available instead of a hardcoded misleading string, and updates the fallback translation to a generic message
https://meta.discourse.org/t/399681
2 Likes
zogstrip
Closed
April 4, 2026, 12:43pm
6
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.