]> source.dussan.org Git - nextcloud-server.git/commitdiff
Fix adding global applicable when removing all other applicables
authorRobin Appelman <icewind@owncloud.com>
Wed, 13 Jan 2016 14:31:26 +0000 (15:31 +0100)
committerRobin Appelman <icewind@owncloud.com>
Wed, 13 Jan 2016 14:31:26 +0000 (15:31 +0100)
apps/files_external/service/storagesservice.php

index 5d3f5f431b9f50e2ab008214f2e5c9309a5bad6f..c0dd263ed66772261328dcffedcf9e03300f65db 100644 (file)
@@ -372,8 +372,8 @@ abstract class StoragesService {
 
                $oldUserCount = count($oldStorage->getApplicableUsers());
                $oldGroupCount = count($oldStorage->getApplicableGroups());
-               $newUserCount = count($oldStorage->getApplicableUsers());
-               $newGroupCount = count($oldStorage->getApplicableGroups());
+               $newUserCount = count($updatedStorage->getApplicableUsers());
+               $newGroupCount = count($updatedStorage->getApplicableGroups());
                $wasGlobal = ($oldUserCount + $oldGroupCount) === 0;
                $isGlobal = ($newUserCount + $newGroupCount) === 0;