Class: ActionDispatch::Routing::Mapper

Inherits:
Object
  • Object
show all
Defined in:
lib/spotlight/rails/routes.rb

Instance Method Summary collapse

Instance Method Details

#spotlight_rootObject



4
5
6
7
8
9
10
# File 'lib/spotlight/rails/routes.rb', line 4

def spotlight_root
  if Spotlight::Exhibit.table_exists?
    root to: "spotlight/home_pages#show", defaults: {id: Spotlight::Exhibit.default.home_page.id} 
  else
    root to: "catalog#index"
  end
end