Method: Notifly::NotificationsController#read

Defined in:
app/controllers/notifly/notifications_controller.rb

#readObject



13
14
15
16
17
18
# File 'app/controllers/notifly/notifications_controller.rb', line 13

def read
  if params[:first_notification_id].present? and params[:last_notification_id].present?
    @notifications = notifications_between
    @notifications.update_all(read: true)
  end
end