diff options
author | Vincent Petry <pvince81@owncloud.com> | 2016-03-07 10:42:36 +0100 |
---|---|---|
committer | Vincent Petry <pvince81@owncloud.com> | 2016-03-07 10:42:36 +0100 |
commit | 60d8046c3574a5cc9c30bdfee57da9e1b3cec27c (patch) | |
tree | 5d05c578f09875d5ef2ca5ea0ded81a0adec487d /apps | |
parent | c07b731689de6fe754e108688ccf71342aad95ef (diff) | |
download | nextcloud-server-60d8046c3574a5cc9c30bdfee57da9e1b3cec27c.tar.gz nextcloud-server-60d8046c3574a5cc9c30bdfee57da9e1b3cec27c.zip |
Fix uploading when free space is unlimited
A federated share can report unlimited quota as -3, so the
ajax/upload.php code needs to be adjusted to block uploads when the free
space is unlimited.
Diffstat (limited to 'apps')
-rw-r--r-- | apps/files/ajax/upload.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/files/ajax/upload.php b/apps/files/ajax/upload.php index 36aaed5ad9e..d14414125f5 100644 --- a/apps/files/ajax/upload.php +++ b/apps/files/ajax/upload.php @@ -138,7 +138,7 @@ $maxHumanFileSize = OCP\Util::humanFileSize($maxUploadFileSize); $totalSize = 0; $isReceivedShare = \OC::$server->getRequest()->getParam('isReceivedShare', false) === 'true'; // defer quota check for received shares -if (!$isReceivedShare) { +if (!$isReceivedShare && $storageStats['freeSpace'] >= 0) { foreach ($files['size'] as $size) { $totalSize += $size; } |