From c550978872483bde790907f1b6accb4bba42c23a Mon Sep 17 00:00:00 2001 From: Jesse Wierzbinski Date: Fri, 26 Apr 2024 19:47:23 -1000 Subject: [PATCH] fix: :ambulance: Fix bug preventing login due to incorrect oauth redirect --- components/sidebars/navigation.vue | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/components/sidebars/navigation.vue b/components/sidebars/navigation.vue index ca055d1..ef7c606 100644 --- a/components/sidebars/navigation.vue +++ b/components/sidebars/navigation.vue @@ -38,6 +38,14 @@ Register +

+ Posts

+ + + Compose + @@ -62,6 +70,10 @@ const appData = useAppData(); const tokenData = useTokenData(); const client = useMegalodon(); +const compose = () => { + alert("Not implemented yet"); +}; + const signIn = async () => { loadingAuth.value = true; @@ -92,12 +104,7 @@ const signIn = async () => { return; } - // Check if URL is on the same origin - if (new URL(url).hostname === useRequestURL().hostname) { - await navigateTo(new URL(url).pathname); - } else { - window.location.href = url; - } + window.location.href = url; }; const signOut = async () => { @@ -115,7 +122,7 @@ const signOut = async () => { tokenData.value.access_token, tokenData.value.access_token, ) - .catch(() => {}); + .catch(() => { }); tokenData.value = null; };