Merge pull request #8715 from nextcloud/objectstore-no-part-files
disable part files for object stores
This commit is contained in:
commit
d05469959e
|
@ -144,6 +144,8 @@ class File extends Node implements IFile {
|
||||||
} else {
|
} else {
|
||||||
// upload file directly as the final path
|
// upload file directly as the final path
|
||||||
$partFilePath = $this->path;
|
$partFilePath = $this->path;
|
||||||
|
|
||||||
|
$this->emitPreHooks($exists);
|
||||||
}
|
}
|
||||||
|
|
||||||
// the part file and target file might be on a different storage in case of a single file storage (e.g. single file share)
|
// the part file and target file might be on a different storage in case of a single file storage (e.g. single file share)
|
||||||
|
@ -188,11 +190,7 @@ class File extends Node implements IFile {
|
||||||
|
|
||||||
try {
|
try {
|
||||||
$view = \OC\Files\Filesystem::getView();
|
$view = \OC\Files\Filesystem::getView();
|
||||||
if ($view) {
|
$run = ($view && $needsPartFile) ? $this->emitPreHooks($exists) : true;
|
||||||
$run = $this->emitPreHooks($exists);
|
|
||||||
} else {
|
|
||||||
$run = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
try {
|
try {
|
||||||
$this->changeLock(ILockingProvider::LOCK_EXCLUSIVE);
|
$this->changeLock(ILockingProvider::LOCK_EXCLUSIVE);
|
||||||
|
|
|
@ -429,4 +429,8 @@ class ObjectStoreStorage extends \OC\Files\Storage\Common {
|
||||||
public function hasUpdated($path, $time) {
|
public function hasUpdated($path, $time) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function needsPartFile() {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue