summaryrefslogtreecommitdiffstats
path: root/apps/files_encryption/lib/migration.php
diff options
context:
space:
mode:
authorVincent Petry <pvince81@owncloud.com>2015-02-27 16:08:05 +0100
committerVincent Petry <pvince81@owncloud.com>2015-02-27 17:14:17 +0100
commit22bc622f9b2488a3c556039096c44d99bc46b1a4 (patch)
treecd5ec1b62785dcce8d4d0920fb2588ee83cf4e03 /apps/files_encryption/lib/migration.php
parent89735ab22b3ca4cf1dedb4de0e9424324281edcc (diff)
downloadnextcloud-server-22bc622f9b2488a3c556039096c44d99bc46b1a4.tar.gz
nextcloud-server-22bc622f9b2488a3c556039096c44d99bc46b1a4.zip
Move keys instead of copy during encryption key migration
Diffstat (limited to 'apps/files_encryption/lib/migration.php')
-rw-r--r--apps/files_encryption/lib/migration.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/files_encryption/lib/migration.php b/apps/files_encryption/lib/migration.php
index b88e671fe56..ad954db7ebb 100644
--- a/apps/files_encryption/lib/migration.php
+++ b/apps/files_encryption/lib/migration.php
@@ -221,7 +221,7 @@ class Migration {
$extension = $this->getExtension($file, $trash);
$targetDir = $this->getTargetDir($user, $filePath, $filename, $extension, $trash);
$this->createPathForKeys($targetDir);
- $this->view->copy($path . '/' . $file, $targetDir . '/fileKey');
+ $this->view->rename($path . '/' . $file, $targetDir . '/fileKey');
$this->renameShareKeys($user, $filePath, $filename, $targetDir, $trash);
}
}
@@ -267,7 +267,7 @@ class Migration {
if (substr($file, 0, strlen($filename) + 1) === $filename . '.') {
$uid = $this->getUidFromShareKey($file, $filename, $trash);
- $this->view->copy($oldShareKeyPath . '/' . $file, $target . '/' . $uid . '.shareKey');
+ $this->view->rename($oldShareKeyPath . '/' . $file, $target . '/' . $uid . '.shareKey');
}
}