diff --git a/src/components/ProfileMenu.vue b/src/components/ProfileMenu.vue
index 6cbb821..ac69e59 100644
--- a/src/components/ProfileMenu.vue
+++ b/src/components/ProfileMenu.vue
@@ -1,7 +1,6 @@
diff --git a/src/composables/hasToken.ts b/src/composables/hasToken.ts
new file mode 100644
index 0000000..7b8d7c2
--- /dev/null
+++ b/src/composables/hasToken.ts
@@ -0,0 +1,6 @@
+import { useCookie } from "#app";
+
+export function hasToken() {
+ const token = useCookie("token").value;
+ return token !== null && token !== undefined && token !== "";
+}
diff --git a/src/composables/logout.ts b/src/composables/logout.ts
index 860ab94..6349738 100644
--- a/src/composables/logout.ts
+++ b/src/composables/logout.ts
@@ -17,10 +17,3 @@ export function logout() {
})
.catch((err) => console.log(err));
}
-
-onMounted(() => {
- const token = useCookie("token").value;
- if (!token) {
- navigateTo("/");
- }
-});
diff --git a/src/pages/user/profile.vue b/src/pages/user/profile.vue
index fdeac50..b73974d 100644
--- a/src/pages/user/profile.vue
+++ b/src/pages/user/profile.vue
@@ -1,6 +1,6 @@
-
-
-
-
-
-
-
-
- Name
- {{profile?.name || profile?.username}}
-
-
- Username
- {{ profile?.username }}@movienight.social
-
-
- Date Joined
- {{ formatDate(profile?.date_joined || "") }}
-
-
-
-
-
-
-