]> source.dussan.org Git - nextcloud-server.git/commitdiff
ignore "Shared"-directory when calculating free space
authorBjoern Schiessle <schiessle@owncloud.com>
Mon, 18 Jun 2012 15:23:54 +0000 (17:23 +0200)
committerBjoern Schiessle <schiessle@owncloud.com>
Mon, 18 Jun 2012 15:23:54 +0000 (17:23 +0200)
lib/fileproxy/quota.php

index f061d48219be6729b081b821bf374d32f5dd6afa..dab41c5e9066969f482f34e129505fb9594e0a1b 100644 (file)
@@ -55,7 +55,9 @@ class OC_FileProxy_Quota extends OC_FileProxy{
         */
        private function getFreeSpace(){
                $rootInfo=OC_FileCache_Cached::get('');
+               $sharedInfo=OC_FileCache_Cached::get('/Shared');
                $usedSpace=isset($rootInfo['size'])?$rootInfo['size']:0;
+               $usedSpace=isset($sharedInfo['size'])?$rootInfo['size']-$sharedInfo['size']:$rootInfo['size'];
                $totalSpace=$this->getQuota();
                if($totalSpace==0){
                        return 0;