diff --git a/lib/ext/environment.rb b/lib/ext/environment.rb index 3011631..c2b33e5 100644 --- a/lib/ext/environment.rb +++ b/lib/ext/environment.rb @@ -3,7 +3,7 @@ require_dependency 'environment' class Environment #reCAPTCHA settings - settings_items :recaptcha_plugin, :type => ActiveSupport::HashWithIndifferentAccess, :default => {} + settings_items :recaptcha_plugin, :type => Hash, :default => {} attr_accessible :recaptcha_plugin_attributes, :recaptcha_version, :recaptcha_private_key, :recaptcha_site_key, :recaptcha_verify_uri def recaptcha_plugin_attributes diff --git a/lib/recaptcha_plugin.rb b/lib/recaptcha_plugin.rb index 9d2d631..4951ea1 100644 --- a/lib/recaptcha_plugin.rb +++ b/lib/recaptcha_plugin.rb @@ -8,10 +8,6 @@ class RecaptchaPlugin < Noosfero::Plugin _("Provides a plugin to Google reCAPTCHA.") end - def self.api_mount_points - [RecaptchaPlugin::API ] - end - def test_captcha(*args) remote_ip = args[0] params = args[1] @@ -26,7 +22,6 @@ class RecaptchaPlugin < Noosfero::Plugin return RecaptchaVerification.hash_error(msg_icve, status, nil, "#{msg_erpa} private_key not defined") if private_key.nil? return RecaptchaVerification.hash_error(msg_icve, status, nil, "#{msg_erpa} version not defined") unless version == 1 || version == 2 - rv = RecaptchaVerification.new if version == 1 verify_uri = 'https://www.google.com/recaptcha/api/verify' diff --git a/views/recaptcha_plugin_admin/index.html.erb b/views/recaptcha_plugin_admin/index.html.erb index e6888dc..8f2d5ff 100644 --- a/views/recaptcha_plugin_admin/index.html.erb +++ b/views/recaptcha_plugin_admin/index.html.erb @@ -8,7 +8,7 @@ <%= _('Value') %> - <%= _('Version (1 or 2)') %> + <%= _('Version number (1 or 2)') %> <%= text_field :environment, :recaptcha_version %> -- libgit2 0.21.2