Module: Panmind::Recaptcha
- Defined in:
- lib/panmind/recaptcha.rb,
lib/panmind/recaptcha/railtie.rb
Defined Under Namespace
Modules: Controller, Helpers, TestHelpers Classes: ConfigurationError, Railtie
Constant Summary collapse
- Version =
'1.0.2'
Class Attribute Summary collapse
-
.private_key ⇒ Object
Returns the value of attribute private_key.
-
.public_key ⇒ Object
Returns the value of attribute public_key.
-
.request_timeout ⇒ Object
Returns the value of attribute request_timeout.
Class Method Summary collapse
Class Attribute Details
.private_key ⇒ Object
Returns the value of attribute private_key.
18 19 20 |
# File 'lib/panmind/recaptcha.rb', line 18 def private_key @private_key end |
.public_key ⇒ Object
Returns the value of attribute public_key.
18 19 20 |
# File 'lib/panmind/recaptcha.rb', line 18 def public_key @public_key end |
.request_timeout ⇒ Object
Returns the value of attribute request_timeout.
18 19 20 |
# File 'lib/panmind/recaptcha.rb', line 18 def request_timeout @request_timeout end |
Class Method Details
.enabled? ⇒ Boolean
29 30 31 |
# File 'lib/panmind/recaptcha.rb', line 29 def enabled? Rails.env.production? || Rails.env.development? end |
.set(options) ⇒ Object
20 21 22 23 24 25 26 27 |
# File 'lib/panmind/recaptcha.rb', line 20 def set() self.private_key, self.public_key = .values_at(:private_key, :public_key) # Defaults # self.request_timeout = [:timeout] || 5 end |