Skip to content

Commit

Permalink
fix: display errors
Browse files Browse the repository at this point in the history
  • Loading branch information
riderx committed Nov 9, 2024
1 parent 744bdc3 commit 44d5137
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions src/vue-pages/register.vue
Original file line number Diff line number Diff line change
Expand Up @@ -62,22 +62,26 @@ const handleSubmit = async () => {
},
})
if (error) {
console.error(error)
console.error('Supabase signup error', error)
toast.error(error.message)
openMessenger()
isLoading.value = false
return
}
try {
await window.Reflio.signup(email.value)
} catch (error) {
console.error(error)
console.error('Reflio signup error', error)
}
if (error || !user) {
isLoading.value = false
return
}
const session = await supabase.auth.getSession()
if (session.error) {
console.error(session.error)
console.error('Supabase session error', session.error)
toast.error(session.error.message)
openMessenger()
isLoading.value = false
return
}
Expand Down

0 comments on commit 44d5137

Please sign in to comment.