Rails - Devise signin(@user) is not working in session -


i used customized controller signin following:

class users::sessionscontroller < devise::sessionscontroller   def create     # super     @user = user.where(:email => user_params[:email]).first     if @user.valid_password? user_params[:password]       sign_in(@user)       @current_user = @user # set current user doesn't make sense        redirect_to '/'     else       render :new     end   end end 

i tried using super, in database level user verified devise never set session. in both 2 cases see record updated in database:

update `users` set `current_sign_in_at` = '...', `last_sign_in_at` = '...', `sign_in_count` = .., `updated_at` = '...' `users`.`id` = 1 


Comments

Popular posts from this blog

php - How to add and update images or image url in Volusion using Volusion API -

javascript - jQuery UI Splitter/Resizable for unlimited amount of columns -

javascript - IE9 error '$'is not defined -