fix quota wrapper reporting negative free_space, breaking user interface

return 0 instead
remotes/origin/stable6
Robin Appelman 12 years ago
parent 88cc2ccb3b
commit 8f10c9571f
  1. 2
      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)));
}
}
}

Loading…
Cancel
Save