]> gitweb.fluxo.info Git - lorea/elgg.git/commitdiff
addresses pull request 472 - group not having an owner is a serious problem - try...
authorcash <cash.costello@gmail.com>
Tue, 22 Jan 2013 19:31:22 +0000 (14:31 -0500)
committercash <cash.costello@gmail.com>
Tue, 22 Jan 2013 19:31:22 +0000 (14:31 -0500)
mod/groups/views/default/groups/profile/summary.php

index 6eca9745e183a97f4abe05d3476be44fa0a03b33..261a746d1727fe1a8569f716ccccdf6ebbdceba1 100644 (file)
@@ -15,8 +15,10 @@ if (!isset($vars['entity']) || !$vars['entity']) {
 $group = $vars['entity'];
 $owner = $group->getOwnerEntity();
 
-if (!$owner) {
-       return true;
+if ($owner) {
+       // not having an owner is very bad so we throw an exception
+       $msg = elgg_echo('InvalidParameterException:IdNotExistForGUID', array('group owner', $group->guid));
+       throw new InvalidParameterException($msg);
 }
 
 ?>