diff --git a/Linphone/Core/CoreContext.swift b/Linphone/Core/CoreContext.swift index 173e36237..1cadfdcbd 100644 --- a/Linphone/Core/CoreContext.swift +++ b/Linphone/Core/CoreContext.swift @@ -26,6 +26,10 @@ import Combine import UniformTypeIdentifiers import Network +#if USE_CRASHLYTICS +import Firebase +#endif + final class CoreContext: ObservableObject { static let shared = CoreContext() @@ -67,6 +71,9 @@ final class CoreContext: ObservableObject { func initialiseCore() throws { +#if USE_CRASHLYTICS + FirebaseApp.configure() +#endif coreQueue.async { LoggingService.Instance.logLevel = LogLevel.Debug diff --git a/Linphone/LinphoneApp.swift b/Linphone/LinphoneApp.swift index a9468c755..dd68f6b7b 100644 --- a/Linphone/LinphoneApp.swift +++ b/Linphone/LinphoneApp.swift @@ -18,18 +18,14 @@ */ import SwiftUI -#if USE_CRASHLYTICS -import Firebase -#endif +import linphonesw let accountTokenNotification = Notification.Name("AccountCreationTokenReceived") class AppDelegate: NSObject, UIApplicationDelegate { func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey : Any]? = nil) -> Bool { -#if USE_CRASHLYTICS - FirebaseApp.configure() -#endif + return true }