making sure this is up to date

This commit is contained in:
cktricky
2014-03-14 14:00:51 -04:00
parent ec8a187833
commit d0e825fc17
4 changed files with 40 additions and 7 deletions
+1 -3
View File
@@ -8,7 +8,6 @@ class SessionsController < ApplicationController
redirect_to home_dashboard_index_path if current_user
end
def create
path = params[:url].present? ? params[:url] : home_dashboard_index_path
begin
@@ -20,10 +19,9 @@ class SessionsController < ApplicationController
if user
if params[:remember_me]
cookies.permanent[:auth_token] = user.auth_token if User.where(:user_id => user.user_id).exists?
cookies.permanent[:auth_token] = user.auth_token if User.where(:user_id => user.user_id).exists?
else
session[:user_id] = user.user_id if User.where(:user_id => user.user_id).exists?
#cookies[:auth_token] = user.auth_token if User.where(:user_id => user.user_id).exists?
end
redirect_to path
else