The default app has not been configured yet

后端 未结 9 1572
予麋鹿
予麋鹿 2020-12-02 19:59

I\'m trying to upgrade my app to the new version of Firebase. I went through the setup guide and edited all of my code to match the new syntax. However, when I run the app,

9条回答
  •  一整个雨季
    2020-12-02 20:55

    Swift 5 - Easy Solution

    func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
    
    return true
    }
    
    
    //MARK:- This function will auto run and firebase will configure successfully
    override init() {
        super.init()
            FirebaseApp.configure()
            // not really needed unless you really need it 
            FIRDatabase.database().persistenceEnabled = true
    }
    

    Happy Coding

提交回复
热议问题