MDL-23797 improved detection of PAGE->context abuse andproblems; fixed incorrect use of this->context instead of this->_context; missing PAGE->context does not throw fatal error any more
This commit is contained in:
+1
-1
@@ -5391,7 +5391,7 @@ class admin_setting_manageportfolio extends admin_setting {
|
||||
function admin_externalpage_setup($section, $extrabutton = '', array $extraurlparams = null, $actualurl = '') {
|
||||
global $CFG, $PAGE, $USER, $SITE, $OUTPUT;
|
||||
|
||||
$PAGE->set_context(get_context_instance(CONTEXT_SYSTEM));
|
||||
$PAGE->set_context(null); // hack - set context to something, by default to system context
|
||||
|
||||
$site = get_site();
|
||||
require_login();
|
||||
|
||||
Reference in New Issue
Block a user