mirror of
https://github.com/moodle/moodle.git
synced 2025-01-17 13:38:32 +01:00
Fixed serious bug that allowed any existing user to use this page. Doh!
This commit is contained in:
parent
41111d545b
commit
f3b9479b3e
@ -69,11 +69,10 @@
|
||||
}
|
||||
|
||||
if (!isadmin()) {
|
||||
if (record_exists_sql("SELECT * FROM user_admins")) {
|
||||
require_login();
|
||||
} else {
|
||||
if (! record_exists_sql("SELECT * FROM user_admins")) {
|
||||
redirect("user.php");
|
||||
}
|
||||
error("You need to be an admin user to use this page.", "$CFG->wwwroot/login/");
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user