Skip to content

Commit 430fae4

Browse files
author
Cedric
committed
use prompt select_account
1 parent 868b945 commit 430fae4

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

packages/auth/ios/RNFBAuth/RNFBAuthModule.m

+9-3
Original file line numberDiff line numberDiff line change
@@ -589,7 +589,10 @@ - (void)invalidate {
589589
[oAuthProviders setValue:provider forKey:providerID];
590590

591591
if (email) {
592-
[provider setCustomParameters:@{@"login_hint": email}];
592+
[provider setCustomParameters:@{@"login_hint": email, @"prompt": @"select_account"}];
593+
}
594+
else {
595+
[provider setCustomParameters:@{@"prompt": @"select_account"}];
593596
}
594597

595598
[provider getCredentialWithUIDelegate:nil
@@ -622,7 +625,10 @@ - (void)invalidate {
622625
[oAuthProviders setValue:provider forKey:providerID];
623626

624627
if (email) {
625-
[provider setCustomParameters:@{@"login_hint": email}];
628+
[provider setCustomParameters:@{@"login_hint": email, @"prompt": @"select_account"}];
629+
}
630+
else {
631+
[provider setCustomParameters:@{@"prompt": @"select_account"}];
626632
}
627633

628634
[provider getCredentialWithUIDelegate:nil
@@ -1367,7 +1373,7 @@ - (NSDictionary *)getJSError:(NSError *)error {
13671373
NSString *sessionKey = [NSString stringWithFormat:@"%@", @([resolver.session hash])];
13681374
cachedResolver[sessionKey] = resolver;
13691375
}
1370-
1376+
13711377
NSString *email = [error userInfo][FIRAuthErrorUserInfoEmailKey];
13721378

13731379
return @{

0 commit comments

Comments
 (0)