Skip to content

Commit

Permalink
fix(occ): handle share wrappers that do not have a circle
Browse files Browse the repository at this point in the history
Signed-off-by: Max <[email protected]>
  • Loading branch information
max-nextcloud authored and ArtificialOwl committed Feb 18, 2025
1 parent 1426bbc commit ae3ded0
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions lib/Command/SharesFiles.php
Original file line number Diff line number Diff line change
Expand Up @@ -223,15 +223,20 @@ private function displayShares(
$sharedTo .= '@' . $recipient->getInstance();
}
}
$circle = $share->getCircle();
$circleField = '';
if ($share->hasCircle()) {
$circle = $share->getCircle();
$circleField = $circle->getDisplayName()
. ' (' . $share->getSharedWith()
. ', ' . Circle::$DEF_SOURCE[$circle->getSource()] . ')';
}
$row = [
$share->getId(),
$share->getFileSource(),
$share->getShareOwner(),
$share->getFileTarget(),
$share->getSharedBy(),
$circle->getDisplayName() . ' (' . $share->getSharedWith()
. ', ' . Circle::$DEF_SOURCE[$circle->getSource()] . ')'
$circleField,
];

if (!$filterRecipient) {
Expand Down

0 comments on commit ae3ded0

Please sign in to comment.