diff --git a/app/controllers/sessions_controller.rb b/app/controllers/sessions_controller.rb index 520635ac..3f6154aa 100644 --- a/app/controllers/sessions_controller.rb +++ b/app/controllers/sessions_controller.rb @@ -21,7 +21,7 @@ def show private def sessions - current_conference&.sessions + Session.where(conference: current_conference) end def filter_params diff --git a/app/views/sessions/_filters.html.erb b/app/views/sessions/_filters.html.erb index 32aa36ec..61a52e07 100644 --- a/app/views/sessions/_filters.html.erb +++ b/app/views/sessions/_filters.html.erb @@ -2,7 +2,7 @@
- <% current_conference.dates.each do |session_date| %> + <% current_conference&.dates&.each do |session_date| %> <%= link_to( session_date.strftime("%a, %d"), url_for([resource, session_filter_params.to_h.merge(starts_at: session_date)]) + current_day_anchor(session_date),