]> gitweb.fluxo.info Git - lorea/elgg.git/commitdiff
Fixes #4018 Refs #3722 merged up to 1.7.14 into master
authorcash <cash.costello@gmail.com>
Sat, 5 Nov 2011 20:22:10 +0000 (16:22 -0400)
committercash <cash.costello@gmail.com>
Sat, 5 Nov 2011 20:22:10 +0000 (16:22 -0400)
engine/lib/entities.php

index 0e89b34bd0063d933d14ac62d57c8d99f928e8f6..711fcbbd7fa0fc91dce59e90151a77823d65e426 100644 (file)
@@ -468,12 +468,10 @@ function can_write_to_container($user_guid = 0, $container_guid = 0, $type = 'al
                        $return = true;
                }
 
-               // Basics, see if the user is a member of the group.
+               // If still not approved, see if the user is a member of the group
                // @todo this should be moved to the groups plugin/library
-               if ($user && $container instanceof ElggGroup) {
-                       if (!$container->isMember($user)) {
-                               $return = false;
-                       } else {
+               if (!$return && $user && $container instanceof ElggGroup) {
+                       if ($container->isMember($user)) {
                                $return = true;
                        }
                }