Files
fizzy/app/controllers/readings_controller.rb
T
David Heinemeier Hansson f725a69dee Let BubbleScoped find its own bucket
Then it will be easier to break things that are double nested out of
that nesting.
2025-04-05 15:44:47 +02:00

14 lines
334 B
Ruby

class ReadingsController < ApplicationController
include BubbleScoped
def create
mark_bubble_notifications_read
@notifications = Current.user.notifications.unread.ordered.limit(20)
end
private
def mark_bubble_notifications_read
Current.user.notifications.unread.where(bubble: @bubble).read_all
end
end