Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't login with another account after logout #1147

Closed
Jaylin0920 opened this issue Dec 10, 2019 · 25 comments
Closed

Can't login with another account after logout #1147

Jaylin0920 opened this issue Dec 10, 2019 · 25 comments

Comments

@Jaylin0920
Copy link

when I logout,I use

let loginManager = LoginManager()
loginManager.logOut()

when I login, I use

 let loginManager = LoginManager()
loginManager.logIn(permissions: [.userBirthday, .userGender, .userHometown, .userLocation], viewController: frVc) { result in
}

when I login,i want to use phone/email and password to change another account, but there show last stored user information everytime,how can i change another account???

If I manually clear the data, Setting->Safari->Advanced->Website Data -> facebook.com,slide left to delete it,it works and i can use phone/email and password to change another account,why sdk ''loginManager.logOut()" does't works,how can i change another account???

@Jaylin0920
Copy link
Author

sdk version, pod 'FacebookLogin', '0.9.0'

@robtimp
Copy link
Contributor

robtimp commented Dec 17, 2019

Unfortunately, that works as intended and there's currently no way to switch accounts within the login dialog once a user has logged in.

I've brought up the need for better multi-user support for Facebook Login and it's on our roadmap. I'll let the team know that developers are requesting it.

@robtimp robtimp closed this as completed Dec 17, 2019
@ay8s
Copy link

ay8s commented Dec 20, 2019

@robtimp +1 for that. Thanks! 👍

@aleksandr-lavrinenko
Copy link

+1 for that, really need this feature

@sparseware
Copy link

Aside from the multi-user support issue, it is also a security and privacy issue as the user is never really logged out (no credentials required to log back in)

@kevin-js
Copy link

kevin-js commented Feb 25, 2020

+1, it would be great if the caching behavior can be specified through a flag in the login call like

let fbLoginManager = LoginManager()
fbLoginManager.logIn(permissions: [.email, .userBirthday], viewController: self, retainSessionOnLogout: false) { result in
...
}

Trying to toggle between accounts has been a major pain point in testing so any updates on the feature roadmap for multi-user support would be much appreciated.

Edit: Thinking further on the above example it might be better to specify the login retention policy in the logout call to transition existing user sessions more seamlessly, that way the end user would be able to toggle accounts the first time they log out instead of logging out/logging back in/logging out again to apply the changes.

@twototwoto
Copy link

+1 for that. Thanks! 👍

@rvsood
Copy link

rvsood commented May 5, 2020

Does anyone have any workaround that they have been using in the meantime? I see in the section on reauthentication on developers.facebook.com where it says apps should create their own methods for switching between Facebook user accounts, but solutions posted on, e.g., StackOverflow are 5+ years old and don't seem to work anymore, and questions on this problem are going unanswered in the Facebook developer community forums.

@joesus
Copy link
Contributor

joesus commented May 5, 2020

sdk version, pod 'FacebookLogin', '0.9.0'

Side note: this pod refers to the deprecated facebook-swift-sdk. You almost certainly want to be using the equivalent code in this repository.

For versions below 7.0 please use:

pod 'FBSDKLoginKit/Swift'
pod 'FBSDKCoreKit/Swift'

For versions 7.0 and above please use:

pod 'FBSDKLoginKit'
pod 'FBSDKCoreKit'

Thanks!

@boygiandi
Copy link

I have the same problem. I login with this Facebook Account, and now, I can't change it. I did logout, clear Safari web data, remove app and re-install. When I tap Login with Facebook, I still see my Facebook Account and no button to change to another one. Where did Facebook store that account ?

@Faydee1220
Copy link

I found out how to log out finally...
We have to go to facebook website and login the account you want to log out, then go to Settings -> Security and Login -> Where You're Logged In, and choose the device you want to log out.
image

@sergeymild
Copy link

can't switch account after logout, previously it works after logout in safari, but now even in safari i can't logout either

@matis-schotte
Copy link

I think the support regarding this issue from Facebook is surprisingly bad. "they will put it on the roadmap" and then they close this issue, not really helping at all, like at least telling us on how to achieve the logout.

I did the same as boygiandi (reset everything), still no success. It takes hours to find a way to achieve this, and I am sure other developers also have the need to use different test users. I didnt see anything in the docs on how to reset the stored credentials. Something might be stored in the keychain?
Thanks to Faydee1220 now I know I can reset that login from that page.
Thanks NOT to facebook for their bad support here.

@kientux
Copy link

kientux commented Aug 6, 2021

Why is this closed? This is really frustating when users want to use different facebook account. Even for developers, when I want to test with other facebook account, the only way is to reset the simulator.

@renanvs
Copy link

renanvs commented Oct 8, 2021

when facebook will implement a real logout that you can use another profile?

@mcfboss
Copy link

mcfboss commented Apr 9, 2022

still nothing?? the issue still there in 2022

@dmytriigolovanov
Copy link

As of April 13, 2022, the issue is current for SDK version 13.1.
This is inadequate behaviour for such functionality, our customers are not able to use other accounts after the first login via Facebook.

Need to re-open the issue and add this in the nearest release.

@Charlottenpl
Copy link

666,amazing😲

@DennisAshford
Copy link

Just to make sure I understand this correctly. Once I am logged into an account on iOS, I cannot logout and log into another Facebook account? I am running into an issue testing 'Login With Facebook' flows because I cannot test it on multiple accounts. And now Facebook is not allowing developers to make new test accounts either. So how are we supposed to test new login flows and other features if we cannot test it on multiple accounts?!

@Taymindis
Copy link

Just uninstall and resintall the app?

@KovtunOleg
Copy link

Hi Guys, it is already autumn 2023 and still we can't switch between multiple accounts, can you please prioritize this issue, as so many people really need this feature in their apps.

@gruj1995
Copy link

It's already spring 2024, and currently, it's still not possible to switch between multiple accounts. Please prioritize rolling out this feature as soon as possible!

@Rogue24
Copy link

Rogue24 commented Jun 21, 2024

If it can't be fixed or there are other solutions, please have the official team provide a clear response and update the documentation accordingly. 😥

@nemecek-filip
Copy link

Sooo it seems that deleting Facebook website data "fixes" this. Settings -> Safari -> Advanced -> Website Data -> search for "Facebook" and "FBCDN" and swipe left to delete.

@TaoLoading
Copy link

It's already the fall of 2024...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests