diff --git a/config/routes.rb b/config/routes.rb index ef984ca9..073bfe3e 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -167,6 +167,7 @@ Osem::Application.routes.draw do end end resource :program, only: [] do + get 'event/:id', to: 'proposals#show', as: :conference_program_event get 'proposal/:id', to: 'proposals#show' # For backward compatibility resources :proposals, except: :destroy do get 'commercials/render_commercial' => 'commercials#render_commercial' @@ -222,15 +223,15 @@ Osem::Application.routes.draw do get '/admin' => redirect('/admin/conferences') + constraints DomainConstraint do + root to: 'conferences#show' + end + unless ENV['OSEM_ROOT_CONFERENCE'].blank? root to: redirect("/conferences/#{ENV['OSEM_ROOT_CONFERENCE']}") else root to: 'conferences#index', via: [:get, :options] end - constraints DomainConstraint do - root to: 'conferences#show' - end - get '/.well-known/apple-developer-merchantid-domain-association', to: 'application#apple_pay' end