Merge pull request #1203 from Retrospring/fix/notification-bugs
Notification dropdown fixes
This commit is contained in:
commit
333af458db
|
@ -27,6 +27,7 @@ class NotificationsController < ApplicationController
|
|||
|
||||
def read
|
||||
current_user.notifications.where(new: true).update_all(new: false) # rubocop:disable Rails/SkipsModelValidations
|
||||
current_user.touch(:notifications_updated_at)
|
||||
|
||||
respond_to do |format|
|
||||
format.turbo_stream do
|
||||
|
|
|
@ -0,0 +1,2 @@
|
|||
-# This is a stub to prevent errors on broken notifications on content being asynchronously destroyed.
|
||||
- logger.error "Notification ##{notification.id} has a target which doesn't exist. (Target: #{notification.target_type}##{notification.target_id})"
|
Loading…
Reference in New Issue