Hi 'basers,
Hilariously I guess i'm attempting to migrate to Firebase 3.x on day zero. That is entirely by coincidence, I had today booked to do update work on an app, saw the pods update, and started following the migration guide.
I've hit one snag so far: "Use of undeclared identifier FIRUserInfo".
I've made sure my podfile includes auth -- I see "Using FirebaseAuth (3.0.2)" in pod update, so that's working.
I've made sure i'm importing auth -- I have "@import FirebaseAuth;" in the header.
I can command-click on FIRUserInfo in Xcode (7.3.1) and sure enough, FirebaseAuth.framework/Headers/FIRUserInfo.h opens up and it looks fine. But I still get the error on build.
I tried cleaning the build folder, restarting xcode etc, no change. I tried adding "#import <FirebaseAuth/FIRUserInfo.h>" but that didn't make any difference (note, that line doesn't generate an error)
Here is the code that doesn't compile (FIRUserInfo as undeclared identifier):
[[FIRAuth auth] signInWithCredential:credential completion:^(FIRUser * _Nullable user, NSError * _Nullable error) {
if (error || user.providerData.count < 1) {
DDLogWarn(@"Firebase login after facebook failed: %@", error);
if( weakSelf.signInCompletionHandler ) {
weakSelf.signInCompletionHandler(false, false, nil);
weakSelf.signInCompletionHandler = nil;
}
} else {
FIRDatabaseReference *userRef = [[FIRDatabase database] reference];
userRef = [userRef child:[NSString stringWithFormat:@"users/%@", user.uid]];
FIRUserInfo *profile = user.providerData.firstObject;
Any suggestions?
thanks.
-tim