Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

More sensible defaults for error handling and messaging

  • Loading branch information...
commit 3615b3d30b04ca8ed6466b2416cbef947bbb2bf2 1 parent cc8dbb3
Philip Nash authored ambethia committed
Showing with 2 additions and 2 deletions.
  1. +2 −2 lib/recaptcha/verify.rb
View
4 lib/recaptcha/verify.rb
@@ -23,7 +23,7 @@ def verify_recaptcha(options = {})
flash[:recaptcha_error] = error
if model
model.valid?
- model.errors.add :captcha, options[:message] || "Word verification response is incorrect, please try again."
+ model.errors.add :base, options[:message] || "Word verification response is incorrect, please try again."
end
return false
else
@@ -34,7 +34,7 @@ def verify_recaptcha(options = {})
flash[:recaptcha_error] = "recaptcha-not-reachable"
if model
model.valid?
- model.errors.add :base, options[:message] || "Oops, we failed to validate your Captcha. Please try again."
+ model.errors.add :base, options[:message] || "Oops, we failed to validate your word verification response. Please try again."
end
return false
rescue Exception => e
Please sign in to comment.
Something went wrong with that request. Please try again.