Skip to content

Commit 3d6e63f

Browse files
Improve quota $path handling for non-Chunked-v2 uploads
Signed-off-by: Josh Richards <josh.t.richards@gmail.com>
1 parent 0111e55 commit 3d6e63f

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

apps/dav/lib/Connector/Sabre/QuotaPlugin.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -202,6 +202,9 @@ public function checkQuota($path, $length = null) {
202202
// use target file name for free space check in case of shared files
203203
$path = rtrim($parentPath, '/') . '/' . $info['name'];
204204
}
205+
if (!$req->getHeader('Destination')) {
206+
$path = dirname($path);
207+
}
205208
$targetOwner = $this->view->getOwner($path);
206209
$freeSpace = $this->getFreeSpace($path);
207210
if ($freeSpace >= 0 && $length > $freeSpace) {

0 commit comments

Comments
 (0)