Skip to content

fix(comments): register event listener for typed comment events#59909

Merged
nickvergessen merged 1 commit intomasterfrom
fix/comments-event-listener-registration
May 4, 2026
Merged

fix(comments): register event listener for typed comment events#59909
nickvergessen merged 1 commit intomasterfrom
fix/comments-event-listener-registration

Conversation

@miaulalala
Copy link
Copy Markdown
Contributor

@miaulalala miaulalala commented Apr 25, 2026

Summary

Since the typed comment events (CommentAddedEvent, CommentUpdatedEvent, etc.) were introduced in NC34, dispatchTyped() dispatches using the exact subclass name. Registering only for CommentsEvent::class means the listener never fires, so comment mention notifications are never created or cleared.

Change introduced in #56076

AI-Assisted-By: Claude Sonnet 4.6 noreply@anthropic.com

Checklist

AI (if applicable)

  • The content of this PR was partly or fully generated using AI

@miaulalala miaulalala added this to the Nextcloud 34 milestone Apr 25, 2026
@miaulalala miaulalala requested a review from CarlSchwan April 25, 2026 10:58
@miaulalala miaulalala self-assigned this Apr 25, 2026
@miaulalala miaulalala added the bug label Apr 25, 2026
@miaulalala miaulalala requested a review from a team as a code owner April 25, 2026 10:58
@miaulalala miaulalala requested review from ArtificialOwl, come-nc and provokateurin and removed request for a team April 25, 2026 10:58
Since the typed comment events (CommentAddedEvent, CommentUpdatedEvent,
etc.) were introduced in NC34, dispatchTyped() dispatches using the exact
subclass name. Registering only for CommentsEvent::class means the listener
never fires, so comment mention notifications are never created or cleared.

AI-Assisted-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Signed-off-by: Anna Larch <anna@nextcloud.com>
@miaulalala miaulalala force-pushed the fix/comments-event-listener-registration branch from 8431485 to 9700875 Compare April 25, 2026 11:01
@miaulalala
Copy link
Copy Markdown
Contributor Author

/backport to stable33

@janepie
Copy link
Copy Markdown
Member

janepie commented Apr 27, 2026

Creating bell notifications works, clearance seems to not work, neither in the notification list nor the bubble in the file list

Comment thread apps/comments/lib/AppInfo/Application.php
@CarlSchwan
Copy link
Copy Markdown
Member

And a followup #60137

@miaulalala
Copy link
Copy Markdown
Contributor Author

Creating bell notifications works, clearance seems to not work, neither in the notification list nor the bubble in the file list

that is fixed in the follow up PR #59918

@nickvergessen
Copy link
Copy Markdown
Member

clearance seems to not work, neither in the notification list nor the bubble in the file list

It used to work as there was a link to go to the comment from the full subject, but since the subject contains mention chip and a file link by now, the subject is no longer linked.

@nickvergessen nickvergessen merged commit 0ff0136 into master May 4, 2026
210 of 220 checks passed
@nickvergessen nickvergessen deleted the fix/comments-event-listener-registration branch May 4, 2026 19:54
@nextcloud-bot nextcloud-bot mentioned this pull request May 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants