mirror of
https://github.com/moodle/moodle.git
synced 2025-04-20 16:04:25 +02:00
MDL-31819: admin: allow install to proceed when multiple admins exist already
This commit is contained in:
parent
48e529c932
commit
a7c9609ba5
@ -306,8 +306,8 @@ if (during_initial_install()) {
|
||||
}
|
||||
}
|
||||
|
||||
// at this stage there can be only one admin - users may change username, so do not rely on that
|
||||
$adminuser = get_complete_user_data('id', $CFG->siteadmins);
|
||||
// at this stage there can be only one admin unless more were added by install - users may change username, so do not rely on that
|
||||
$adminuser = get_complete_user_data('id', reset(explode(',', $CFG->siteadmins)));
|
||||
|
||||
if ($adminuser->password === 'adminsetuppending') {
|
||||
// prevent installation hijacking
|
||||
|
Loading…
x
Reference in New Issue
Block a user