vendredi 15 janvier 2016

Devise sign_in method doesn't sign in user

Inside my controller I write

class UsersController < ApplicationController
  def create
    user = User.create(params[:user])

    sign_in(user, {})

    redirect_to home_path
  end
end

However, the method does absolutely nothing. The sessions are not set and the app acts as if the user has not signed in. How do I fix this? I'm using Devise 3.0 and Rails 3.2.

Aucun commentaire:

Enregistrer un commentaire