mirror of
https://github.com/moodle/moodle.git
synced 2025-01-18 22:08:20 +01:00
Close wide-open hacking hole! This script wasn't checking for admin
user in the case where the site has been defined already. Oops. Fixed now.
This commit is contained in:
parent
9c055aa5d2
commit
ce15d1784c
@ -2,7 +2,11 @@
|
||||
|
||||
require("../config.php");
|
||||
|
||||
$course = get_site();
|
||||
if ($course = get_site()) {
|
||||
if (!isadmin()) {
|
||||
error("You need to be admin to edit this page");
|
||||
}
|
||||
}
|
||||
$course->format = "social"; // override
|
||||
|
||||
/// If data submitted, then process and store.
|
||||
|
Loading…
x
Reference in New Issue
Block a user