mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-03-10 05:35:05 +08:00
missing await
sign out on catch
This commit is contained in:
parent
bef07017b9
commit
1c2c5991d3
1 changed files with 2 additions and 1 deletions
|
@ -407,7 +407,7 @@ export async function signInWithGoogle() {
|
|||
}
|
||||
//create database object for the new user
|
||||
// try {
|
||||
const response = Ape.users.create(name);
|
||||
const response = await Ape.users.create(name);
|
||||
if (response.status !== 200) {
|
||||
throw response;
|
||||
}
|
||||
|
@ -459,6 +459,7 @@ export async function signInWithGoogle() {
|
|||
await Ape.users.delete();
|
||||
await signedInUser.user.delete();
|
||||
}
|
||||
signOut();
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue