Skip to content

Commit

Permalink
Fix(StorageService) Type error
Browse files Browse the repository at this point in the history
Signed-off-by: Marcel Klehr <[email protected]>
  • Loading branch information
marcelklehr committed Sep 2, 2023
1 parent 8203e76 commit 3f5c528
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions lib/Service/StorageService.php
Original file line number Diff line number Diff line change
Expand Up @@ -174,15 +174,12 @@ public function getFilesInMount(int $storageId, int $rootId, array $models, int
return;
}

while (
/** @var array{fileid:int,mimetype:int} $file */
$file = $files->fetch()
) {
while ($file = $files->fetch()) {
yield [
'fileid' => (int) $file['fileid'],
'image' => in_array($file['mimetype'], $imageTypes),
'video' => in_array($file['mimetype'], $videoTypes),
'audio' => in_array($file['mimetype'], $audioTypes),
'image' => in_array((int) $file['mimetype'], $imageTypes),
'video' => in_array((int) $file['mimetype'], $videoTypes),
'audio' => in_array((int) $file['mimetype'], $audioTypes),
];
}

Expand Down

0 comments on commit 3f5c528

Please sign in to comment.