summaryrefslogtreecommitdiffstats
path: root/apps/dav/lib/CardDAV/PhotoCache.php
diff options
context:
space:
mode:
authorCarl Schwan <carl@carlschwan.eu>2022-05-06 00:01:08 +0200
committerCarl Schwan <carl@carlschwan.eu>2022-05-16 11:05:54 +0200
commitf7be76125f885d66caac4a8d6697e121dce52708 (patch)
tree5abff07b0daa376ef90ad60b648611d2fc82d809 /apps/dav/lib/CardDAV/PhotoCache.php
parent829490ab7a02579c6b31573c3f53428e86cbf2e0 (diff)
downloadnextcloud-server-f7be76125f885d66caac4a8d6697e121dce52708.tar.gz
nextcloud-server-f7be76125f885d66caac4a8d6697e121dce52708.zip
Fix more psalm issues
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
Diffstat (limited to 'apps/dav/lib/CardDAV/PhotoCache.php')
-rw-r--r--apps/dav/lib/CardDAV/PhotoCache.php13
1 files changed, 5 insertions, 8 deletions
diff --git a/apps/dav/lib/CardDAV/PhotoCache.php b/apps/dav/lib/CardDAV/PhotoCache.php
index 3051d2d48ba..777a0b0e169 100644
--- a/apps/dav/lib/CardDAV/PhotoCache.php
+++ b/apps/dav/lib/CardDAV/PhotoCache.php
@@ -63,15 +63,9 @@ class PhotoCache {
}
/**
- * @param int $addressBookId
- * @param string $cardUri
- * @param int $size
- * @param Card $card
- *
- * @return ISimpleFile
* @throws NotFoundException
*/
- public function get($addressBookId, $cardUri, $size, Card $card) {
+ public function get(int $addressBookId, string $cardUri, int $size, Card $card): ISimpleFile {
$folder = $this->getFolder($addressBookId, $cardUri);
if ($this->isEmpty($folder)) {
@@ -120,7 +114,10 @@ class PhotoCache {
return !$folder->fileExists('nophoto');
}
- private function getFile(ISimpleFolder $folder, int $size): ISimpleFile {
+ /**
+ * @param float|-1 $size
+ */
+ private function getFile(ISimpleFolder $folder, $size): ISimpleFile {
$ext = $this->getExtension($folder);
if ($size === -1) {