From 2bb29d7224dba3b1b2cc514d3dfabc4d59e34e3e Mon Sep 17 00:00:00 2001 From: Aaron van Geffen Date: Sun, 1 Mar 2020 17:09:58 +0100 Subject: [PATCH] Minor optimisation to Download::getChildAlbumIds. --- controllers/Download.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/controllers/Download.php b/controllers/Download.php index 8dfaa9a..58ec832 100644 --- a/controllers/Download.php +++ b/controllers/Download.php @@ -84,11 +84,11 @@ class Download { $ids = []; - $albums = Tag::getAlbums($parent_id, 0, PHP_INT_MAX, 'object'); - foreach($albums as $album) + $albums = Tag::getAlbums($parent_id, 0, PHP_INT_MAX); + foreach ($albums as $album) { - $ids[] = $album->id_tag; - $ids = array_merge($ids, $this->getChildAlbumIds($album->id_tag)); + $ids[] = $album['id_tag']; + $ids = array_merge($ids, $this->getChildAlbumIds($album['id_tag'])); } return $ids;