Merge branch 'w49_MDL-37061_m24_invalidlang' of git://github.com/skodak/moodle into MOODLE_24_STABLE
This commit is contained in:
@@ -1122,6 +1122,10 @@ function get_moodle_cookie() {
|
||||
function session_set_user($user) {
|
||||
$_SESSION['USER'] = $user;
|
||||
unset($_SESSION['USER']->description); // conserve memory
|
||||
if (isset($_SESSION['USER']->lang)) {
|
||||
// Make sure it is a valid lang pack name.
|
||||
$_SESSION['USER']->lang = clean_param($_SESSION['USER']->lang, PARAM_LANG);
|
||||
}
|
||||
sesskey(); // init session key
|
||||
|
||||
if (PHPUNIT_TEST) {
|
||||
|
||||
Reference in New Issue
Block a user