Skip to content
Snippets Groups Projects
Commit ddf73781 authored by joe's avatar joe Committed by agata
Browse files

set the correct recaptcha key where you have an empty one

parent 0b62a6e0
Branches
Tags
1 merge request!3Noblogs 5.4
...@@ -111,8 +111,14 @@ class ReCAPTCHAPlugin extends WPPlugin ...@@ -111,8 +111,14 @@ class ReCAPTCHAPlugin extends WPPlugin
// set the default options // set the default options
function register_default_options() { function register_default_options() {
if ($this->options) if ($this->options) {
if ($this->keys_missing()) {
$this->options['site_key'] = GLOBAL_RECAPTCHA_KEY;
$this->options['secret'] = GLOBAL_RECAPTCHA_PRIVATE_KEY;
WPPlugin::add_options($this->options_name, $this->options);
}
return; return;
}
$option_defaults = array(); $option_defaults = array();
$old_options = WPPlugin::retrieve_options("recaptcha"); $old_options = WPPlugin::retrieve_options("recaptcha");
if ($old_options) { if ($old_options) {
...@@ -172,9 +178,11 @@ class ReCAPTCHAPlugin extends WPPlugin ...@@ -172,9 +178,11 @@ class ReCAPTCHAPlugin extends WPPlugin
} }
function missing_keys_notice() { function missing_keys_notice() {
/*
if ($this->keys_missing()) { if ($this->keys_missing()) {
$this->create_error_notice('reCAPTCHA API Keys are missing.'); $this->create_error_notice('reCAPTCHA API Keys are missing.');
} }
*/
} }
function validate_dropdown($array, $key, $value) { function validate_dropdown($array, $key, $value) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment