Skip to content

Commit

Permalink
Switch to signInWithPopup.
Browse files Browse the repository at this point in the history
This is a bit of an annoying UI but is better than doing the more confusing options to keep signInWithRedirect.

Part of #693.
  • Loading branch information
jkomoros committed Apr 20, 2024
1 parent 3f92f01 commit c967070
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/actions/user.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ export const AUTO_MARK_READ_DELAY = 5000;
import {
GoogleAuthProvider,
signInWithCredential,
linkWithRedirect,
signInWithRedirect,
signInWithPopup,
linkWithPopup,
signInAnonymously,
signOut as firebaseSignOut,
getRedirectResult,
Expand Down Expand Up @@ -195,11 +195,11 @@ export const signIn = () : ThunkSomeAction => (dispatch, getState) => {
console.warn('Unexpectedly didn\'t have user');
return;
}
linkWithRedirect(user, provider);
linkWithPopup(user, provider);
return;
}

signInWithRedirect(auth, provider).catch(err => {
signInWithPopup(auth, provider).catch(err => {
dispatch({type:SIGNIN_FAILURE, error: err});
});

Expand Down

0 comments on commit c967070

Please sign in to comment.