diff options
Diffstat (limited to 'mod/pages/views')
-rw-r--r-- | mod/pages/views/default/pages/group_module.php | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/mod/pages/views/default/pages/group_module.php b/mod/pages/views/default/pages/group_module.php index f36e30442..6befb1c65 100644 --- a/mod/pages/views/default/pages/group_module.php +++ b/mod/pages/views/default/pages/group_module.php @@ -37,10 +37,12 @@ if (!$content) { $content = '<p>' . elgg_echo('pages:none') . '</p>'; } -$new_link = elgg_view('output/url', array( - 'href' => "pages/add/$group->guid", - 'text' => elgg_echo('pages:add'), -)); -$content .= "<span class='elgg-widget-more'>$new_link</span>"; +if ($group->canWriteToContainer()) { + $new_link = elgg_view('output/url', array( + 'href' => "pages/add/$group->guid", + 'text' => elgg_echo('pages:add'), + )); + $content .= "<span class='elgg-widget-more'>$new_link</span>"; +} echo elgg_view_module('info', '', $content, array('header' => $header)); |