Skip to content

Commit

Permalink
add a load_subsite! impl to Dcv::Sites::ReadingRooms (DLC-1157)
Browse files Browse the repository at this point in the history
  • Loading branch information
barmintor committed Sep 25, 2024
1 parent 5736365 commit 2f5866c
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions app/controllers/concerns/dcv/sites/reading_rooms.rb
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,10 @@ def load_subsite
super
@subsite
end

def load_subsite!
_subsite = load_subsite
return _subsite if _subsite
raise ActiveRecord::RecordNotFound
end
end

0 comments on commit 2f5866c

Please sign in to comment.