navigation MDL-20204 Now checks an icon implements renderable interface before trying to pass it to OUTPUTs render method
This commit is contained in:
@@ -411,7 +411,7 @@ class navigation_node {
|
||||
$title = $this->title;
|
||||
}
|
||||
|
||||
if ($this->icon !== null) {
|
||||
if ($this->icon instanceof renderable) {
|
||||
$icon = $OUTPUT->render($this->icon);
|
||||
$content = $icon.$content; // use CSS for spacing of icons
|
||||
} else if ($this->helpbutton !== null) {
|
||||
|
||||
Reference in New Issue
Block a user