mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-09 03:32:00 +09:00
Fix fatal error when "lang" URL parameter is given on an external page
This commit is contained in:
parent
9429c7fbc8
commit
7fce9fcc39
1 changed files with 2 additions and 1 deletions
|
|
@ -317,13 +317,14 @@ class Context
|
||||||
$lang->loadDirectory(RX_BASEDIR . 'common/lang', 'common');
|
$lang->loadDirectory(RX_BASEDIR . 'common/lang', 'common');
|
||||||
$lang->loadDirectory(RX_BASEDIR . 'modules/module/lang', 'module');
|
$lang->loadDirectory(RX_BASEDIR . 'modules/module/lang', 'module');
|
||||||
self::setLangType(self::$_instance->lang_type = $lang_type);
|
self::setLangType(self::$_instance->lang_type = $lang_type);
|
||||||
self::set('lang', self::$_instance->lang = $lang);
|
|
||||||
|
|
||||||
// Set global variables for backward compatibility.
|
// Set global variables for backward compatibility.
|
||||||
$GLOBALS['oContext'] = self::$_instance;
|
$GLOBALS['oContext'] = self::$_instance;
|
||||||
$GLOBALS['__Context__'] = &self::$_user_vars;
|
$GLOBALS['__Context__'] = &self::$_user_vars;
|
||||||
$GLOBALS['_time_zone'] = config('locale.default_timezone');
|
$GLOBALS['_time_zone'] = config('locale.default_timezone');
|
||||||
$GLOBALS['lang'] = &$lang;
|
$GLOBALS['lang'] = &$lang;
|
||||||
|
self::$_user_vars->lang = $lang;
|
||||||
|
self::$_instance->lang = $lang;
|
||||||
|
|
||||||
// set session handler
|
// set session handler
|
||||||
if(self::isInstalled() && config('session.use_db'))
|
if(self::isInstalled() && config('session.use_db'))
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue