aboutsummaryrefslogtreecommitdiff
path: root/mod/groups/start.php
diff options
context:
space:
mode:
authorCash Costello <cash.costello@gmail.com>2011-11-20 19:48:40 -0500
committerCash Costello <cash.costello@gmail.com>2011-11-20 19:48:40 -0500
commita35e00f095cfbe924af589260649674f6b05384a (patch)
tree733a01b66fc595e3c04f80a08a3004a2461bffe9 /mod/groups/start.php
parentcd2ed1772e6dc52d68d286536333127b65c74935 (diff)
downloadelgg-a35e00f095cfbe924af589260649674f6b05384a.tar.gz
elgg-a35e00f095cfbe924af589260649674f6b05384a.tar.bz2
added check in case something goes wrong with the container entity of a discussion
Diffstat (limited to 'mod/groups/start.php')
-rw-r--r--mod/groups/start.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/mod/groups/start.php b/mod/groups/start.php
index 7dcf6b7c4..09362cbbc 100644
--- a/mod/groups/start.php
+++ b/mod/groups/start.php
@@ -830,7 +830,7 @@ function discussion_add_to_river_menu($hook, $type, $return, $params) {
if (elgg_instanceof($object, 'object', 'groupforumtopic')) {
if ($item->annotation_id == 0) {
$group = $object->getContainerEntity();
- if ($group->canWriteToContainer() || elgg_is_admin_logged_in()) {
+ if ($group && ($group->canWriteToContainer() || elgg_is_admin_logged_in())) {
$options = array(
'name' => 'reply',
'href' => "#groups-reply-$object->guid",