Commit f34f3cd6 authored by Richard Mansfield's avatar Richard Mansfield
Browse files

Fix fatal error when displaying empty blog blocks


Signed-off-by: default avatarRichard Mansfield <richardm@catalyst.net.nz>
parent 5f19b576
......@@ -631,7 +631,7 @@ class BlockInstance {
}
// if the artefact has a feed and the view is public, display a feed icon
if ($this->get('blocktype') == 'blog' && $this->get('view_obj')->is_public()) {
if ($this->get('blocktype') == 'blog' && !empty($configdata['artefactid']) && $this->get_view()->is_public()) {
$smarty->assign('hasfeed', true);
$smarty->assign('feedlink', get_config('wwwroot') . 'artefact/blog/atom.php?artefact='
. $configdata['artefactid'] . '&view=' . $this->get('view'));
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment