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>
This commit is contained in:
Tigran Mkrtchyan 2020-12-07 17:57:07 +01:00
parent e02c9ec1bf
commit f3513f3fe4
1 changed files with 1 additions and 1 deletions

View File

@ -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 {