config/routes.rb in enjoy_cms-0.2.0.beta vs config/routes.rb in enjoy_cms-0.2.0.1.beta
- old
+ new
@@ -1,14 +1,19 @@
Enjoy::Engine.routes.draw do
+ routes_config = Enjoy.configuration.routes_config
+
+
get 'contacts' => 'contacts#new', as: :contacts
post 'contacts' => 'contacts#create', as: :create_contacts
get 'contacts/sent' => 'contacts#sent', as: :contacts_sent
get 'search' => 'search#index', as: :search
resources :news, only: [:index, :show]
- root to: 'home#index'
+ if routes_config and routes_config[:root_path]
+ root to: routes_config[:root_path]
+ end
get '*slug' => 'pages#show'
resources :pages, only: [:show]
end