Commit 5224262
Changed files (2)
app
controllers
config
app/controllers/logins_controller.rb
@@ -9,7 +9,7 @@ class LoginsController < ApplicationController
def create
if @session = @login_command.run(self)
session[:user_session_id] = @session.id
- redirect_to dashboard_path
+ redirect_to root_path
else
flash[:error] = I18n.translate(:invalid_credentials)
render :new
config/routes.rb
@@ -1,7 +1,7 @@
Mocode::Application.routes.draw do
resources :logins, only: [:new, :create]
get 'dashboard', to: 'dashboard#index'
- root 'logins#new'
+ root 'dashboard#index'
# The priority is based upon order of creation: first created -> highest priority.
# See how all your routes lay out with "rake routes".