summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/files/storage/wrapper/quota.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/files/storage/wrapper/quota.php b/lib/files/storage/wrapper/quota.php
index bc2d8939760..e2da8cf2e05 100644
--- a/lib/files/storage/wrapper/quota.php
+++ b/lib/files/storage/wrapper/quota.php
@@ -48,7 +48,7 @@ class Quota extends Wrapper {
return \OC\Files\SPACE_NOT_COMPUTED;
} else {
$free = $this->storage->free_space($path);
- return min($free, ($this->quota - $used));
+ return min($free, (max($this->quota - $used, 0)));
}
}
}