]> source.dussan.org Git - nextcloud-server.git/commitdiff
Silence a warning from psalm with explanation
authorCôme Chilliet <come.chilliet@nextcloud.com>
Mon, 19 Dec 2022 13:13:11 +0000 (14:13 +0100)
committerbackportbot-nextcloud[bot] <backportbot-nextcloud[bot]@users.noreply.github.com>
Sat, 1 Apr 2023 13:12:05 +0000 (13:12 +0000)
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
lib/private/Files/Storage/Local.php

index fe6a6d6e21ad53d1822de37c5d12e87f9aa36800..0f213adc9ba3026cf71381bc8f41125a94c0fd94 100644 (file)
@@ -617,6 +617,7 @@ class Local extends \OC\Files\Storage\Common {
        }
 
        public function writeStream(string $path, $stream, int $size = null): int {
+               /** @var int|false $result We consider here that returned size will never be a float because we write less than 4GB */
                $result = $this->file_put_contents($path, $stream);
                if (is_resource($stream)) {
                        fclose($stream);