diff options
author | Tigran Mkrtchyan <tigran.mkrtchyan@desy.de> | 2020-12-07 17:57:07 +0100 |
---|---|---|
committer | Tigran Mkrtchyan <tigran.mkrtchyan@desy.de> | 2020-12-07 18:11:40 +0100 |
commit | f3513f3fe4dc52143798e60deb4367f2c829029f (patch) | |
tree | b0cb06d9428085cc44f855f07e5b3ac2f6a61f1f /lib/private/Files/Storage/Local.php | |
parent | e02c9ec1bfc7eaabafe640dce87adb5efb013ad0 (diff) | |
download | nextcloud-server-f3513f3fe4dc52143798e60deb4367f2c829029f.tar.gz nextcloud-server-f3513f3fe4dc52143798e60deb4367f2c829029f.zip |
files: Local#writeStream should use it's own file_put_contents
The OC\Files\Storage\Local#writeStream use system provided file_put_contents.
However, it overrides file_put_contents, thus expects that the default behaviour
can be different.
Use Local#file_put_contents in writeStream to benefit from class specific functionality.
Signed-off-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
Diffstat (limited to 'lib/private/Files/Storage/Local.php')
-rw-r--r-- | lib/private/Files/Storage/Local.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/Files/Storage/Local.php b/lib/private/Files/Storage/Local.php index f0a81f48930..ed80a4718d3 100644 --- a/lib/private/Files/Storage/Local.php +++ b/lib/private/Files/Storage/Local.php @@ -556,7 +556,7 @@ class Local extends \OC\Files\Storage\Common { } public function writeStream(string $path, $stream, int $size = null): int { - $result = file_put_contents($this->getSourcePath($path), $stream); + $result = $this->file_put_contents($path, $stream); if ($result === false) { throw new GenericFileException("Failed write steam to $path"); } else { |