mirror of
https://github.com/moodle/moodle.git
synced 2025-08-02 23:59:41 +02:00
Merge branch 'MDL-69910-calendar-protectusername' of https://github.com/brendanheywood/moodle
This commit is contained in:
commit
29da421a85
1 changed files with 1 additions and 1 deletions
|
@ -18,7 +18,7 @@ if (empty($CFG->enablecalendarexport)) {
|
||||||
$checkuserid = !empty($userid) && $user = $DB->get_record('user', array('id' => $userid), 'id,password');
|
$checkuserid = !empty($userid) && $user = $DB->get_record('user', array('id' => $userid), 'id,password');
|
||||||
//allowing for fallback check of old url - MDL-27542
|
//allowing for fallback check of old url - MDL-27542
|
||||||
$checkusername = !empty($username) && $user = $DB->get_record('user', array('username' => $username), 'id,password');
|
$checkusername = !empty($username) && $user = $DB->get_record('user', array('username' => $username), 'id,password');
|
||||||
if (!$checkuserid && !$checkusername) {
|
if ((!$checkuserid && !$checkusername) || !$user) {
|
||||||
//No such user
|
//No such user
|
||||||
die('Invalid authentication');
|
die('Invalid authentication');
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue