File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11<template >
22 <div class =" page" >
33 <div class =" confetti" >
4- <ConfettiExplosion :force =" 0.9" v-if =" showConfetti" />
4+ <ConfettiExplosion
5+ :force =" 0.9"
6+ v-if =" showConfetti"
7+ />
58 </div >
69
710 <div class =" verification-container" >
@@ -63,14 +66,27 @@ onMounted(async () => {
6366 .find (param => param .startsWith (' refresh_token=' ))
6467 ?.split (' =' )[1 ]
6568
66- if (! accessToken ) {
67- currentState .value = ' error'
68- errorMessage .value = ' Missing access token'
69- return
70- }
71- if (! refreshToken ) {
69+ const error_ = hashParams
70+ .find (param => param .startsWith (' error=' ))
71+ ?.split (' =' )[1 ]
72+
73+ const error_code = hashParams
74+ .find (param => param .startsWith (' error_code=' ))
75+ ?.split (' =' )[1 ]
76+
77+ const error_description = hashParams
78+ .find (param => param .startsWith (' error_description=' ))
79+ ?.split (' =' )[1 ]
80+
81+ if (error_ || ! accessToken ||! refreshToken ) {
82+ if (error_description ) {
83+ errorMessage .value = error_description
84+ } else if (! accessToken ) {
85+ errorMessage .value = ' Missing access token'
86+ } else if (! refreshToken ) {
87+ errorMessage .value = ' Missing refresh token'
88+ }
7289 currentState .value = ' error'
73- errorMessage .value = ' Missing refresh token'
7490 return
7591 }
7692
Original file line number Diff line number Diff line change @@ -15,6 +15,9 @@ export default defineConfig((env) => {
1515 vueDevTools ( ) ,
1616 Icons ( ) ,
1717 ] ,
18+ server : {
19+ port : 3000
20+ } ,
1821 resolve : {
1922 alias : {
2023 '@' : fileURLToPath ( new URL ( './src' , import . meta. url ) )
You can’t perform that action at this time.
0 commit comments