Skip to content

Commit

Permalink
Merge pull request #2565 from nextcloud/enh/noid/fix-getallbackupvolumes
Browse files Browse the repository at this point in the history
fix getAllBackupVolumes
  • Loading branch information
szaimen authored May 19, 2023
2 parents 9388ec5 + 14a77ea commit 08ff51c
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions php/src/Docker/DockerActionManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -522,8 +522,15 @@ private function getBackupVolumes(string $id) : array

private function getAllBackupVolumes() : array {
$id = 'nextcloud-aio-apache';

return array_unique($this->getBackupVolumes($id));
$backupVolumesArray = $this->getBackupVolumes($id);
// Flatten array
$backupVolumesArrayFlat = iterator_to_array(
new \RecursiveIteratorIterator(
new \RecursiveArrayIterator($backupVolumesArray)
),
$use_keys = false
);
return array_unique($backupVolumesArrayFlat);
}

private function GetRepoDigestsOfContainer(string $containerName) : ?array {
Expand Down

0 comments on commit 08ff51c

Please sign in to comment.