Skip to content

Commit

Permalink
Fix new post notifications not being sent
Browse files Browse the repository at this point in the history
It seems that f50122a actually caused
a regression. With the order of execution of extensions, this event
listener was always being executed before the discussion metadata
was updated, and the listener priority was not actually necessary.

Fixes flarum/framework#1646
  • Loading branch information
tobyzerner committed Nov 21, 2018
1 parent c3b9a52 commit 7fae63a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Listener/SendNotificationWhenReplyIsPosted.php
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public function whenPosted(Posted $event)
$notify = $discussion->readers()
->where('users.id', '!=', $post->user_id)
->where('discussion_user.subscription', 'follow')
->where('discussion_user.last_read_post_number', $discussion->last_post_number - 1)
->where('discussion_user.last_read_post_number', $discussion->last_post_number)
->get();

$this->notifications->sync(
Expand Down

0 comments on commit 7fae63a

Please sign in to comment.