diff options
author | John Molakvoæ <skjnldsv@users.noreply.github.com> | 2021-10-23 11:18:52 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-10-23 11:18:52 +0200 |
commit | f4e4a85fcfc8ee25d4d398f5fa8aa657d4eaf08a (patch) | |
tree | 96e82a5891f10907da215efd3737fb9429cebe90 /lib | |
parent | c5e9f379bdef3ed2669aa8dbcd16afffc1d839a2 (diff) | |
parent | dae769d082ffcde2c4f0b4cb27e7afd4c35023d7 (diff) | |
download | nextcloud-server-f4e4a85fcfc8ee25d4d398f5fa8aa657d4eaf08a.tar.gz nextcloud-server-f4e4a85fcfc8ee25d4d398f5fa8aa657d4eaf08a.zip |
Merge pull request #27440 from nextcloud/is-file-handle
Diffstat (limited to 'lib')
-rw-r--r-- | lib/private/Files/Storage/Wrapper/Encryption.php | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/private/Files/Storage/Wrapper/Encryption.php b/lib/private/Files/Storage/Wrapper/Encryption.php index e44b7afe6fd..a52c87ec5a1 100644 --- a/lib/private/Files/Storage/Wrapper/Encryption.php +++ b/lib/private/Files/Storage/Wrapper/Encryption.php @@ -391,7 +391,7 @@ class Encryption extends Wrapper { if ($this->util->isExcluded($fullPath) === false) { $size = $unencryptedSize = 0; $realFile = $this->util->stripPartialFileExtension($path); - $targetExists = $this->file_exists($realFile) || $this->file_exists($path); + $targetExists = $this->is_file($realFile) || $this->file_exists($path); $targetIsEncrypted = false; if ($targetExists) { // in case the file exists we require the explicit module as @@ -855,7 +855,7 @@ class Encryption extends Wrapper { */ protected function readFirstBlock($path) { $firstBlock = ''; - if ($this->storage->file_exists($path)) { + if ($this->storage->is_file($path)) { $handle = $this->storage->fopen($path, 'r'); $firstBlock = fread($handle, $this->util->getHeaderSize()); fclose($handle); @@ -872,7 +872,7 @@ class Encryption extends Wrapper { protected function getHeaderSize($path) { $headerSize = 0; $realFile = $this->util->stripPartialFileExtension($path); - if ($this->storage->file_exists($realFile)) { + if ($this->storage->is_file($realFile)) { $path = $realFile; } $firstBlock = $this->readFirstBlock($path); @@ -920,7 +920,7 @@ class Encryption extends Wrapper { */ protected function getHeader($path) { $realFile = $this->util->stripPartialFileExtension($path); - $exists = $this->storage->file_exists($realFile); + $exists = $this->storage->is_file($realFile); if ($exists) { $path = $realFile; } |