MDL-42648 lib: Clean theme throws exception if set_pagelayout is called too late.

This commit is contained in:
Mary Evans
2013-11-02 00:57:32 +00:00
parent c9ee1a77a5
commit 8a5c822a99
+6 -1
View File
@@ -3063,7 +3063,12 @@ EOD;
'data-blockregion' => $displayregion,
'data-droptarget' => '1'
);
return html_writer::tag($tag, $this->blocks_for_region($region), $attributes);
if ($this->page->blocks->region_has_content($region, $this)) {
$content = $this->blocks_for_region($region);
} else {
$content = '';
}
return html_writer::tag($tag, $content, $attributes);
}
/**