Skip to content

Commit

Permalink
fixes for rails 7
Browse files Browse the repository at this point in the history
  • Loading branch information
stcorbett committed Jun 22, 2023
1 parent c0c7eda commit 57cfa5f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/models/location.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ class Location
attr_reader :hosting_location, :site_id

def self.all
location_names = Event.configured_year.order("hosting_location ASC").uniq.pluck(:hosting_location, :site_id)
location_names = Event.configured_year.order("hosting_location ASC").pluck(:hosting_location, :site_id).uniq

location_names.collect do |name, site_id|
Location.new(name, site_id)
Expand All @@ -25,7 +25,7 @@ def update_event_attributes(event_params)

Event.transaction do
events.each do |event|
event.update_attributes!(event_params)
event.update!(event_params)
end

@hosting_location = event_params[:hosting_location]
Expand Down

0 comments on commit 57cfa5f

Please sign in to comment.