Steps to reproduce
- Enable browser push notifications for User A.
- Set User A’s notification level for Category A to “Watching First Post”.
- Log in as User B (in incognito) and post in Category A (Post A)
Expected: User A would receive a browser push notification for Post A.
Actual: User A receives no browser push notification. Notifications (i.e. in the user menu) and email alerts work as expected.
Likely Cause
In the PostAlerter
notify_first_post_watchers
passes Notification.types[:watching_first_post]
as the type
to create_notification
: https://github.com/discourse/discourse/blob/master/app/services/post_alerter.rb#L133
create_notification
restricts the creation of notification alerts to NOTIFIABLE_TYPES
which does not include :watching_first_post
: https://github.com/discourse/discourse/blob/master/app/services/post_alerter.rb#L196
This may be intentional, however reading through this discussion, I suspect not?