Ad

How To Fix Build Error With FBSDKLoginKit In Xcode

- 1 answer

My ios app was working fine until I ran "pod install" and updated all of my pods. I'm now getting an error when trying to build in Xcode.

FBSDKLoginKit/FBSDKLoginManagerLoginResult.m:43:25: No known class method for selector 'dictionary:setObject:forKey:'

Here are the FB pod versions used:

Installing FBSDKCoreKit (5.0.0)
Installing FBSDKLoginKit (4.44.1)

Those are not specified in my podfile. I think they're installed as part of FirebaseAuth which is in my podfile.

How can I resolve this?

Ad

Answer

Add pod 'FBSDKCoreKit', '~> 4.44' to the Podfile.

There's a bug in the 4.x versions of FBSDKLoginKit. Its podspec allow major version updates to its FBSDKCoreKit dependency, but the code doesn't comply.

There's no FBSDKCoreKit version specified in the 4.44.1 version like there is in the 5.0.0 version.

The suggested Podfile change is a workaround for the podspec problem.

The current version of FirebaseUI requires version 4.x of FBSDKLoginKit.

Ad
source: stackoverflow.com
Ad