diff --git a/src/components/AuthorizeUser.vue b/src/components/AuthorizeUser.vue
index b39aa0e..97d2f0c 100644
--- a/src/components/AuthorizeUser.vue
+++ b/src/components/AuthorizeUser.vue
@@ -3,6 +3,7 @@ import { onBeforeMount, ref } from "vue"
import { useRoute, useRouter } from "vue-router"
import { useGitHubLogin } from "@/hooks/useGitHubLogin.hook"
+import { consumeGithubOAuthReturnPath } from "@/modules/user/service/oauthReturnPath"
import { signIn } from "@/modules/user/service/signIn"
const route = useRoute()
@@ -22,7 +23,13 @@ onBeforeMount(async () => {
await saveCredentials(token)
}
- router.replace({ name: "Home" })
+ const returnPath = consumeGithubOAuthReturnPath()
+
+ if (!hasError.value && returnPath) {
+ router.replace(returnPath)
+ } else {
+ router.replace({ name: "Home" })
+ }
}
})
diff --git a/src/components/SignInGithub.vue b/src/components/SignInGithub.vue
index 98a458a..2675bbf 100644
--- a/src/components/SignInGithub.vue
+++ b/src/components/SignInGithub.vue
@@ -1,20 +1,34 @@
-
+
Sign in with