RailsCasts Pro episodes are now free!

Learn more or hide this

izuoshi's Profile

GitHub User: izuoshi

Comments by

Avatar

I did this to delete that error message

module UsersHelper
def remove_sensitive_error_messages_from_user(user)
@user.errors.full_messages.delete_if { |msg| msg =~ /digest/ }
end
end

and when you want to display error message in views, call that method with a given user object.