diff options
author | Vincent Petry <pvince81@owncloud.com> | 2015-04-21 18:28:15 +0200 |
---|---|---|
committer | Vincent Petry <pvince81@owncloud.com> | 2015-04-21 18:28:15 +0200 |
commit | ffc796edcb02f9428ecd706ff4af4c5583928f2b (patch) | |
tree | 773d6d96c0d8a16d70351175bd01d2469da713a1 /lib/private/connector | |
parent | 9dc12d40d846d54e024812c2c23c402073f8dd03 (diff) | |
download | nextcloud-server-ffc796edcb02f9428ecd706ff4af4c5583928f2b.tar.gz nextcloud-server-ffc796edcb02f9428ecd706ff4af4c5583928f2b.zip |
Do not trash part files, delete directly
Diffstat (limited to 'lib/private/connector')
-rw-r--r-- | lib/private/connector/sabre/file.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/private/connector/sabre/file.php b/lib/private/connector/sabre/file.php index dc678c0894f..100aba13668 100644 --- a/lib/private/connector/sabre/file.php +++ b/lib/private/connector/sabre/file.php @@ -117,7 +117,7 @@ class File extends Node implements IFile { $target = $storage->fopen($internalPartPath, 'wb'); if ($target === false) { \OC_Log::write('webdav', '\OC\Files\Filesystem::fopen() failed', \OC_Log::ERROR); - $this->fileView->unlink($partFilePath); + $storage->unlink($internalPartPath); // because we have no clue about the cause we can only throw back a 500/Internal Server Error throw new Exception('Could not write file contents'); } @@ -166,7 +166,7 @@ class File extends Node implements IFile { $fileExists = $storage->file_exists($internalPath); if ($renameOkay === false || $fileExists === false) { \OC_Log::write('webdav', '\OC\Files\Filesystem::rename() failed', \OC_Log::ERROR); - $this->fileView->unlink($partFilePath); + $storage->unlink($internalPartPath); throw new Exception('Could not rename part file to final file'); } } catch (\OCP\Files\LockNotAcquiredException $e) { |