diff --git a/components/App.vue b/components/App.vue
index 6e6e0a2..8520118 100644
--- a/components/App.vue
+++ b/components/App.vue
@@ -30,7 +30,7 @@
-
diff --git a/components/apps/AppList.vue b/components/apps/AppList.vue
index 84e2379..cb4572d 100644
--- a/components/apps/AppList.vue
+++ b/components/apps/AppList.vue
@@ -4,17 +4,19 @@
Loading...
+
([]);
export function useApps() {
const { canRunCommands, run } = useCommands();
+
const shortenImage = (image: string) =>
image.replace("ghcr.io/", "gh:").replace(":latest", "");
+
const shortenVolumes = (volumes: string): string[] =>
volumes
.split(",")
@@ -22,8 +24,6 @@ export function useApps() {
.filter(Boolean);
async function refresh() {
- if (!canRunCommands.value) return;
-
const list: Array
= await run('dx.list');
const running: string[] = await run('dx.ps');
@@ -43,10 +43,6 @@ export function useApps() {
}
onMounted(() => {
- if (canRunCommands.value) {
- return refresh();
- }
-
const detach = watch(canRunCommands, () => {
refresh();
detach();
diff --git a/composables/useRouter.ts b/composables/useRouter.ts
index 69e0ef4..c7faa64 100644
--- a/composables/useRouter.ts
+++ b/composables/useRouter.ts
@@ -24,6 +24,7 @@ const topPages = [
path: "/settings",
name: "Settings",
icon: "settings",
+ protected: true,
component: Settings,
},
];