Don't check display name on null

Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com>
This commit is contained in:
Git'Fellow 2023-12-03 10:15:11 +01:00 committed by backportbot-nextcloud[bot]
parent 730876183b
commit c8ba5d5817
1 changed files with 2 additions and 2 deletions

View File

@ -353,10 +353,10 @@ class AlbumMapper {
switch ($row['collaborator_type']) {
case self::TYPE_USER:
$displayName = $this->userManager->get($row['collaborator_id'])->getDisplayName();
$displayName = $this->userManager->get($row['collaborator_id'])?->getDisplayName();
break;
case self::TYPE_GROUP:
$displayName = $this->groupManager->get($row['collaborator_id'])->getDisplayName();
$displayName = $this->groupManager->get($row['collaborator_id'])?->getDisplayName();
break;
case self::TYPE_LINK:
$displayName = $this->l->t('Public link');