lib/devise_zxcvbn/model.rb in devise_zxcvbn-2.1.0 vs lib/devise_zxcvbn/model.rb in devise_zxcvbn-2.1.1

- old
+ new

@@ -47,10 +47,10 @@ module ClassMethods Devise::Models.config(self, :min_password_score) Devise::Models.config(self, :zxcvbn_tester) def password_score(user, arg_email=nil) - password = user.respond_to?(:password) ? user.password : user + password = user.respond_to?(:password) ? user.password.to_s : user zxcvbn_weak_words = [] if arg_email zxcvbn_weak_words += [arg_email, *DeviseZxcvbn::EmailTokeniser.split(arg_email)]