diff options
author | Robin Appelman <icewind@owncloud.com> | 2015-09-07 17:19:50 +0200 |
---|---|---|
committer | Morris Jobke <hey@morrisjobke.de> | 2015-10-05 20:55:57 +0200 |
commit | b1ce53f890d51aec97d2423651188e14c445c72e (patch) | |
tree | 2d70d8c48bcc6a6618fe470f6cda535fee61abba /lib/private/files/storage/wrapper | |
parent | cf9fb034c436825cee2e90dc8ec3b30b3c93d222 (diff) | |
download | nextcloud-server-b1ce53f890d51aec97d2423651188e14c445c72e.tar.gz nextcloud-server-b1ce53f890d51aec97d2423651188e14c445c72e.zip |
use a normal rename when moving from the same storage in the encryption wrapper
Diffstat (limited to 'lib/private/files/storage/wrapper')
-rw-r--r-- | lib/private/files/storage/wrapper/encryption.php | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/private/files/storage/wrapper/encryption.php b/lib/private/files/storage/wrapper/encryption.php index c80e935b982..e9aabe2e5a2 100644 --- a/lib/private/files/storage/wrapper/encryption.php +++ b/lib/private/files/storage/wrapper/encryption.php @@ -424,6 +424,9 @@ class Encryption extends Wrapper { * @return bool */ public function moveFromStorage(Storage $sourceStorage, $sourceInternalPath, $targetInternalPath, $preserveMtime = true) { + if ($sourceStorage === $this) { + return $this->rename($sourceInternalPath, $targetInternalPath); + } // TODO clean this up once the underlying moveFromStorage in OC\Files\Storage\Wrapper\Common is fixed: // - call $this->storage->moveFromStorage() instead of $this->copyBetweenStorage |