-
Notifications
You must be signed in to change notification settings - Fork 268
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NoMethodError in Devise::TwoFactorAuthenticationController#update #30
Comments
I suppose this is because your otp_secret_key is nil. def need_two_factor_authentication?(request)
not otp_secret_key.nil?
end Please also check example: https://github.com/Houdini/TwoFactorAuthenticationExample Close this issue for now. |
Hi, I added this snippet to the user model, restarted the server, and i still have the same error message. This is only happening when i type in the wrong code (correct code works, 3 try lock the user are all working). I'm assuming the redirection logic when wrong code entered? |
Also i have version 1.1 |
Hello, could you be more specific in how to get this error? |
So first login screen is my own traditional login with user name and password, and once it's verified, it goes to the two_factor_authentication page which asking for the 6 digit code. I enter a wrong code by purpose, and that's when i got the error. The error was from update action in TwoFactorAuthenticationController. I have a regular user controller/admin user controller, and users table and admin_users table. Have you tested with this scenario? def update
end |
some details from the log, the error happened after updating the second_factor_attempts_count: Started PUT "/admin_users/two_factor_authentication" for 127.0.0.1 at 2014-04-21 10:14:56 -0400 A NoMethodError occurred in two_factor_authentication#update: undefined method |
Problem resolved. It's the devise version 2.2.3 doesn't have find_message function defined, 2.2.4 and above does. Upgraded to version 2.2.8, works fine now. Thanks again for all the help. |
I am still using devise 2.1.3 and don't want to deal with updgrading right now, so I made a fork that doesn't use find_message. https://github.com/appRenaissance/two_factor_authentication |
Hi,
I'm receiving this error message when I try to test entering a wrong code, any thoughts?
NoMethodError in Devise::TwoFactorAuthenticationController#update
undefined method `find_message' for #Devise::TwoFactorAuthenticationController:0x007f8f0e051eb0
Or is it possible to generate the controller or views and modify them like Devise does?
Thanks,
The text was updated successfully, but these errors were encountered: