diff --git a/lib/Service/AppsService.php b/lib/Service/AppsService.php index 50d3649e79655f0092a4457bab151b1aa98b2051..4f8c88ecb1d4ec15aa71d9dd680050d6aee69afe 100644 --- a/lib/Service/AppsService.php +++ b/lib/Service/AppsService.php @@ -23,7 +23,7 @@ class AppsService { private IURLGenerator $urlGenerator; private IRootFolder $rootFolder; - private const DEFAULT_ORDER = array("/apps/snappymail/", "/apps/calendar/", "/apps/files/" , "/apps/photos/", "/apps/memories/", "/apps/contacts/", "/apps/onlyoffice/new?id=onlyoffice_docx", "/apps/onlyoffice/new?id=onlyoffice_xlsx", "/apps/onlyoffice/new?id=onlyoffice_pptx", "/apps/notes/", "/apps/tasks/", "https://spot.murena.io" , "https://murena.com" ); + private const DEFAULT_ORDER = array("/apps/snappymail/", "/apps/calendar/", "/apps/files/" , "/apps/memories/", "/apps/contacts/", "/apps/onlyoffice/new?id=onlyoffice_docx", "/apps/onlyoffice/new?id=onlyoffice_xlsx", "/apps/onlyoffice/new?id=onlyoffice_pptx", "/apps/notes/", "/apps/tasks/", "https://spot.murena.io" , "https://murena.com" ); public function __construct( $appName, IConfig $config, @@ -123,6 +123,10 @@ class AppsService { } $entriesByHref[$entry["href"]] = $entry; } + // Remove photos, replace in order correctly with memories + $order = str_replace('/apps/photos/', '/apps/memories/', $order); + $order = array_unique($order); + unset($entriesByHref['/apps/photos/']); /* Sort apps according to order Since "entriesByHref" is indexed by "href", simply reverse the order array and prepend in "entriesByHref"