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

AuthenticationToken.current == nil #2403

Open
5 tasks done
chengssir opened this issue Apr 28, 2024 · 1 comment
Open
5 tasks done

AuthenticationToken.current == nil #2403

chengssir opened this issue Apr 28, 2024 · 1 comment

Comments

@chengssir
Copy link

Checklist before submitting a bug report

Xcode version

15.1

Facebook iOS SDK version

17.0.0

Dependency Manager

CocoaPods

SDK Framework

Core

Goals

get token

Expected results

token

Actual results

AuthenticationToken.current == nil

Steps to reproduce

    let faceBook = LoginManager()
    faceBook.logOut()
    guard let configuration = LoginConfiguration(
        permissions:["public_profile"],
        tracking: .enabled
    )
    else {
        return
    }
    faceBook.logIn(configuration: configuration) { result in
        switch result {
           case .cancelled, .failed:
            break
           case .success(_, _, let token):
            print("######################## \(AuthenticationToken.current)")
        }
    }

Code samples & details

// INSERT YOUR CODE HERE
var example = "Example code" 111
@zhong-meta
Copy link

Hello,

In response to the upcoming changes to ATT enforcement, we made changes to the iOS SDK and the SDK no longer provides valid user access tokens in scenarios where the user opts out of ATT. The access token validation or Graph API requests may throw errors like OAuthException - “Invalid OAuth access token - Cannot parse access token”. Our recommendation is that users integrate Limited Login following the official documentation:
https://developers.facebook.com/docs/facebook-login/limited-login/ios
https://developers.facebook.com/docs/facebook-login/limited-login/unity/

See more details here.

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

2 participants