mirror of
https://github.com/moodle/moodle.git
synced 2025-04-20 07:56:06 +02:00
MDL-12592 do not execute theme_setup() if header already printed; merged from MOODLE_19_STABLE
This commit is contained in:
parent
1d21b2377e
commit
32462b2c10
@ -3187,6 +3187,11 @@ function theme_setup($theme = '', $params=NULL) {
|
||||
|
||||
global $CFG, $THEME, $SESSION, $USER, $HTTPSPAGEREQUIRED;
|
||||
|
||||
/// Do not mess with THEME if header already printed - this would break all the extra stuff in global $THEME from print_header()!!
|
||||
if (defined('HEADER_PRINTED')) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (empty($theme)) {
|
||||
$theme = current_theme();
|
||||
}
|
||||
@ -7029,4 +7034,4 @@ function is_in_popup() {
|
||||
|
||||
|
||||
// vim:autoindent:expandtab:shiftwidth=4:tabstop=4:tw=140:
|
||||
?>
|
||||
?>
|
||||
|
Loading…
x
Reference in New Issue
Block a user