mirror of
https://github.com/moodle/moodle.git
synced 2025-01-18 05:58:34 +01:00
MDL-51217 auth: check if recaptcha enabled for current plugin
This commit is contained in:
parent
a853f15fc3
commit
0f7f30021a
@ -235,12 +235,11 @@ class auth_plugin_email extends auth_plugin_base {
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns whether or not the captcha element is enabled, and the admin settings fulfil its requirements.
|
||||
* Returns whether or not the captcha element is enabled.
|
||||
* @return bool
|
||||
*/
|
||||
function is_captcha_enabled() {
|
||||
global $CFG;
|
||||
return $this->config->recaptcha;
|
||||
return get_config("auth/{$this->authtype}", 'recaptcha');
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -1,6 +1,10 @@
|
||||
This files describes API changes in /auth/* - plugins,
|
||||
information provided here is intended especially for developers.
|
||||
|
||||
=== 3.0 ===
|
||||
|
||||
* login_signup_form::signup_captcha_enabled() now calls is_captcha_enabled() from the current auth plugin instead of from auth_email
|
||||
|
||||
=== 2.9 ===
|
||||
|
||||
* Do not update user->firstaccess from any auth plugin, the complete_user_login() does it automatically.
|
||||
|
@ -536,7 +536,7 @@ class auth_plugin_base {
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns whether or not the captcha element is enabled, and the admin settings fulfil its requirements.
|
||||
* Returns whether or not the captcha element is enabled.
|
||||
*
|
||||
* @abstract Implement in child classes
|
||||
* @return bool
|
||||
|
Loading…
x
Reference in New Issue
Block a user