Skip to content

Commit

Permalink
Merge pull request #2168 from nextcloud/backport/2163/stable27
Browse files Browse the repository at this point in the history
[stable27] Don't check display name on null
  • Loading branch information
artonge committed Dec 5, 2023
2 parents 418b480 + e34c8c5 commit f1537a4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/Album/AlbumMapper.php
Original file line number Diff line number Diff line change
Expand Up @@ -353,10 +353,10 @@ public function getCollaborators(int $albumId): array {

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');
Expand Down

0 comments on commit f1537a4

Please sign in to comment.