Commit 3a43cd5ef1e61df885bc59e267d2d9374d200293
1 parent
88227abb
Exists in
master
Rails 4 changes
Showing
3 changed files
with
2 additions
and
7 deletions
Show diff stats
lib/ext/environment.rb
... | ... | @@ -3,7 +3,7 @@ require_dependency 'environment' |
3 | 3 | class Environment |
4 | 4 | |
5 | 5 | #reCAPTCHA settings |
6 | - settings_items :recaptcha_plugin, :type => ActiveSupport::HashWithIndifferentAccess, :default => {} | |
6 | + settings_items :recaptcha_plugin, :type => Hash, :default => {} | |
7 | 7 | attr_accessible :recaptcha_plugin_attributes, :recaptcha_version, :recaptcha_private_key, :recaptcha_site_key, :recaptcha_verify_uri |
8 | 8 | |
9 | 9 | def recaptcha_plugin_attributes | ... | ... |
lib/recaptcha_plugin.rb
... | ... | @@ -8,10 +8,6 @@ class RecaptchaPlugin < Noosfero::Plugin |
8 | 8 | _("Provides a plugin to Google reCAPTCHA.") |
9 | 9 | end |
10 | 10 | |
11 | - def self.api_mount_points | |
12 | - [RecaptchaPlugin::API ] | |
13 | - end | |
14 | - | |
15 | 11 | def test_captcha(*args) |
16 | 12 | remote_ip = args[0] |
17 | 13 | params = args[1] |
... | ... | @@ -26,7 +22,6 @@ class RecaptchaPlugin < Noosfero::Plugin |
26 | 22 | |
27 | 23 | return RecaptchaVerification.hash_error(msg_icve, status, nil, "#{msg_erpa} private_key not defined") if private_key.nil? |
28 | 24 | return RecaptchaVerification.hash_error(msg_icve, status, nil, "#{msg_erpa} version not defined") unless version == 1 || version == 2 |
29 | - | |
30 | 25 | rv = RecaptchaVerification.new |
31 | 26 | if version == 1 |
32 | 27 | verify_uri = 'https://www.google.com/recaptcha/api/verify' | ... | ... |
views/recaptcha_plugin_admin/index.html.erb