do not require authentication for root redirect

This commit is contained in:
wvengen 2014-01-15 16:24:49 +01:00
parent ecb2f2a015
commit 151f851799
3 changed files with 8 additions and 6 deletions

View file

@ -62,9 +62,4 @@ class HomeController < ApplicationController
redirect_to my_profile_path
end
# redirect to root, going to default foodcoop when none given
def redirect_to_foodcoop
redirect_to root_path
end
end

View file

@ -31,4 +31,11 @@ class SessionsController < ApplicationController
session[:return_to] = nil
redirect_to login_url, :notice => I18n.t('sessions.logged_out')
end
# redirect to root, going to default foodcoop when none given
# this may not be so much session-related, but it must be somewhere
def redirect_to_foodcoop
redirect_to root_path
end
end

View file

@ -6,7 +6,7 @@ Foodsoft::Application.routes.draw do
get "sessions/new"
root :to => 'home#redirect_to_foodcoop'
root :to => 'sessions#redirect_to_foodcoop'
scope '/:foodcoop' do