I use the Devise to handle the authentications in my app and have public_activity to record things and have a log. Now I need to add a record to the log when a failed login occurs and when a account gets locked. How can I do this?
In Rails when using the Devise gem, how to log failed logins and lockups?
836 views Asked by THpubs At
1
You can use Warden's
after_authenticationhook as devise is built on warden. Put this in anconfig/initializers/devise_hooks.rb:Read details in wardens wiki