diff options
author | Bjoern Schiessle <bjoern@schiessle.org> | 2018-10-24 16:49:39 +0200 |
---|---|---|
committer | Bjoern Schiessle <bjoern@schiessle.org> | 2018-10-24 16:53:39 +0200 |
commit | d76a87f3b0ad3f96373984db31470463b1fdc946 (patch) | |
tree | c5323311a03027f89045bbb9745b4c59109a14f0 /lib/private/Encryption | |
parent | 87657fffd8aa3e7e8211b3c866b56042e78a922a (diff) | |
download | nextcloud-server-d76a87f3b0ad3f96373984db31470463b1fdc946.tar.gz nextcloud-server-d76a87f3b0ad3f96373984db31470463b1fdc946.zip |
skip already decrypted files on decrypt all command
Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
Diffstat (limited to 'lib/private/Encryption')
-rw-r--r-- | lib/private/Encryption/DecryptAll.php | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/private/Encryption/DecryptAll.php b/lib/private/Encryption/DecryptAll.php index 12bda54a52e..16eee347334 100644 --- a/lib/private/Encryption/DecryptAll.php +++ b/lib/private/Encryption/DecryptAll.php @@ -252,6 +252,12 @@ class DecryptAll { */ protected function decryptFile($path) { + // skip already decrypted files + $fileInfo = $this->rootView->getFileInfo($path); + if ($fileInfo !== false && !$fileInfo->isEncrypted()) { + return true; + } + $source = $path; $target = $path . '.decrypted.' . $this->getTimestamp(); |