diff options
author | blizzz <blizzz@arthur-schiwon.de> | 2022-05-31 14:22:05 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-31 14:22:05 +0200 |
commit | df89e7fd393706b1099cbc7345dcb1f069142e43 (patch) | |
tree | 021b3e0b075363005f6b96b32b47316ededa9ca1 | |
parent | 9a444a8be6c68ebe87d4833e51e5b0ee11b8c1c5 (diff) | |
parent | be99ea969eb1a8b56ff1495c43f083021356c345 (diff) | |
download | nextcloud-server-df89e7fd393706b1099cbc7345dcb1f069142e43.tar.gz nextcloud-server-df89e7fd393706b1099cbc7345dcb1f069142e43.zip |
Merge pull request #32485 from nextcloud/debt/noid/psalm-streamer-fh
[Psalm] Fix docblock for addFileFromStream
-rw-r--r-- | lib/private/Streamer.php | 4 | ||||
-rw-r--r-- | lib/public/AppFramework/Http/ZipResponse.php | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/lib/private/Streamer.php b/lib/private/Streamer.php index 80ab5a5524c..88204be9805 100644 --- a/lib/private/Streamer.php +++ b/lib/private/Streamer.php @@ -148,13 +148,13 @@ class Streamer { /** * Add a file to the archive at the specified location and file name. * - * @param string $stream Stream to read data from + * @param resource $stream Stream to read data from * @param string $internalName Filepath and name to be used in the archive. * @param int $size Filesize * @param int|bool $time File mtime as int, or false * @return bool $success */ - public function addFileFromStream($stream, $internalName, $size, $time) { + public function addFileFromStream($stream, string $internalName, int $size, $time): bool { $options = []; if ($time) { $options = [ diff --git a/lib/public/AppFramework/Http/ZipResponse.php b/lib/public/AppFramework/Http/ZipResponse.php index 7495583ae12..23e9f1f7a94 100644 --- a/lib/public/AppFramework/Http/ZipResponse.php +++ b/lib/public/AppFramework/Http/ZipResponse.php @@ -37,7 +37,7 @@ use OCP\IRequest; * @since 15.0.0 */ class ZipResponse extends Response implements ICallbackResponse { - /** @var array{internalName: string, resource: string, size: int, time: int}[] Files to be added to the zip response */ + /** @var array{internalName: string, resource: resource, size: int, time: int}[] Files to be added to the zip response */ private array $resources = []; /** @var string Filename that the zip file should have */ private string $name; |