Skip to content

Commit

Permalink
chore: small optimization
Browse files Browse the repository at this point in the history
Co-authored-by: Côme Chilliet <[email protected]>
Signed-off-by: Git'Fellow <[email protected]>
  • Loading branch information
solracsf and come-nc authored Jul 11, 2024
1 parent a527567 commit 9c481bf
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions lib/Controller/FolderController.php
Original file line number Diff line number Diff line change
Expand Up @@ -304,13 +304,8 @@ private function buildOCSResponseXML(string $format, DataResponse $data): V1Resp
}

private function folderDataForXML(array $data): array {
$groups = [];

if (isset($data['group_details'])) {
$groups = $data['group_details'];
unset($data['group_details']);
}

$groups = $data['group_details'] ?? [];
unset($data['group_details']);
$data['groups'] = [];
foreach ($groups as $id => $group) {
$data['groups'][] = [
Expand Down

0 comments on commit 9c481bf

Please sign in to comment.