I\'m new to RoR and stuck with this devise problem. I want to allow users to sign in with email OR username (registration with username is already ok).
I followed these
The problem is with the field "login", remove :authentication_keys => [:login] and add attr_accessor :login in your User model.
:authentication_keys => [:login]
attr_accessor :login
User