Swift 3 to Swift 4: FirebaseApp must be configured (when it is)

ios swift

319 просмотра

1 ответ

1144 Репутация автора

This is the error:

2017-11-08 21:56:14.897695-0200 htchhkr-development[4861:265024] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'The default FIRApp instance must be configured before the default FIRAuthinstance can be initialized. One way to ensure that is to call `[FIRApp configure];` (`FirebaseApp.configure()` in Swift) in the App Delegate's `application:didFinishLaunchingWithOptions:` (`application(_:didFinishLaunchingWithOptions:)` in Swift).'

This is where it loads:

func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {


FirebaseApp use to be FIRApp, but Swift told me gently that it's no longer called FIRApp, but rather FirebaseApp. I renamed, but now I get that error.

What to do here?

Автор: Rosenberg Источник Размещён: 09.11.2017 12:09

Ответы (1)

0 плюса

1 Репутация автора

I was having this same problem. I migrated to swift 4 and ran my program and got the same error. I then ran pod update in terminal and that seemed to fix my problem.

Автор: user3664899 Размещён: 31.01.2018 09:42
Вопросы из категории :