Skip to content

Commit f537c7b

Browse files
committed
fix: check that object store backend supports multi part uploads
Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
1 parent f52145f commit f537c7b

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

apps/dav/lib/Upload/ChunkingV2Plugin.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -278,6 +278,9 @@ private function checkPrerequisites(bool $checkUploadMetadata = true): void {
278278
if (!$this->uploadFolder->getStorage()->instanceOfStorage(IChunkedFileWrite::class)) {
279279
throw new StorageInvalidException('Storage does not support chunked file writing');
280280
}
281+
if ($this->uploadFolder->getStorage()->instanceOfStorage(ObjectStoreStorage::class) && !$this->uploadFolder->getStorage()->getObjectStore() instanceof IObjectStoreMultiPartUpload) {
282+
throw new StorageInvalidException('Storage does not support multi part uploads');
283+
}
281284

282285
if ($checkUploadMetadata) {
283286
if ($this->uploadId === null || $this->uploadPath === null) {

0 commit comments

Comments
 (0)