Other files ignored by Codecov
lib/notifications/base.rb
was deleted.
2 | 2 | class NotificationsController < Notifications::ApplicationController |
|
3 | 3 | def index |
|
4 | 4 | @notifications = notifications.includes(:actor).order("id desc").page(params[:page]) |
|
5 | + | @notification_groups = @notifications.group_by { |note| note.created_at.to_date } |
|
5 | 6 | ||
6 | - | unread_ids = @notifications.reject(&:read?).select(&:id) |
|
7 | + | unread_ids = @notifications.unread.ids |
|
7 | 8 | Notification.read!(current_user, unread_ids) |
|
8 | - | ||
9 | - | @notification_groups = @notifications.group_by { |note| note.created_at.to_date } |
|
10 | 9 | end |
|
11 | 10 | ||
12 | 11 | def read |