Merge branch 'MDL-64385-master' of git://github.com/aanabit/moodle
This commit is contained in:
+4
-2
@@ -6436,8 +6436,10 @@ function send_password_change_info($user) {
|
||||
function email_is_not_allowed($email) {
|
||||
global $CFG;
|
||||
|
||||
// Comparing lowercase domains.
|
||||
$email = strtolower($email);
|
||||
if (!empty($CFG->allowemailaddresses)) {
|
||||
$allowed = explode(' ', $CFG->allowemailaddresses);
|
||||
$allowed = explode(' ', strtolower($CFG->allowemailaddresses));
|
||||
foreach ($allowed as $allowedpattern) {
|
||||
$allowedpattern = trim($allowedpattern);
|
||||
if (!$allowedpattern) {
|
||||
@@ -6456,7 +6458,7 @@ function email_is_not_allowed($email) {
|
||||
return get_string('emailonlyallowed', '', $CFG->allowemailaddresses);
|
||||
|
||||
} else if (!empty($CFG->denyemailaddresses)) {
|
||||
$denied = explode(' ', $CFG->denyemailaddresses);
|
||||
$denied = explode(' ', strtolower($CFG->denyemailaddresses));
|
||||
foreach ($denied as $deniedpattern) {
|
||||
$deniedpattern = trim($deniedpattern);
|
||||
if (!$deniedpattern) {
|
||||
|
||||
Reference in New Issue
Block a user