summaryrefslogtreecommitdiffstats
path: root/apps/settings
diff options
context:
space:
mode:
authorFerdinand Thiessen <opensource@fthiessen.de>2024-07-08 16:23:52 +0200
committerFerdinand Thiessen <opensource@fthiessen.de>2024-07-10 01:35:24 +0200
commita96b5940dd9d80c6ea6fbb5faa6ef7d1a7cc6734 (patch)
treeb6d0368a9e25c52dfcbb28f8a816dfbfd77f4ff8 /apps/settings
parent4fc77eca47947e833f371253d80db0cc0cad4fbf (diff)
downloadnextcloud-server-a96b5940dd9d80c6ea6fbb5faa6ef7d1a7cc6734.tar.gz
nextcloud-server-a96b5940dd9d80c6ea6fbb5faa6ef7d1a7cc6734.zip
chore: Make active apps initial state consistent with OCS API
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
Diffstat (limited to 'apps/settings')
-rw-r--r--apps/settings/src/components/AppStoreDiscover/AppLink.vue8
1 files changed, 3 insertions, 5 deletions
diff --git a/apps/settings/src/components/AppStoreDiscover/AppLink.vue b/apps/settings/src/components/AppStoreDiscover/AppLink.vue
index 1ce19ad7319..703adb9f041 100644
--- a/apps/settings/src/components/AppStoreDiscover/AppLink.vue
+++ b/apps/settings/src/components/AppStoreDiscover/AppLink.vue
@@ -18,12 +18,10 @@ import { loadState } from '@nextcloud/initial-state'
import { generateUrl } from '@nextcloud/router'
import { defineComponent } from 'vue'
import { RouterLink } from 'vue-router'
+import type { INavigationEntry } from '../../../../../core/src/types/navigation'
-const knownRoutes = Object.fromEntries(
- Object.entries(
- loadState<Record<string, { app?: string, href: string }>>('core', 'apps'),
- ).map(([k, v]) => [v.app ?? k, v.href]),
-)
+const apps = loadState<INavigationEntry[]>('core', 'apps')
+const knownRoutes = Object.fromEntries(apps.map((app) => [app.app ?? app.id, app.href]))
/**
* This component either shows a native link to the installed app or external size - or a router link to the appstore page of the app if not installed