Change Guard init location

release
Laurent 1 year ago
parent ae0fb47c74
commit c9b812cd7e
  1. 3
      PadelClub/AppDelegate.swift
  2. 4
      PadelClub/Data/DataStore.swift

@ -14,6 +14,9 @@ class AppDelegate : NSObject, UIApplicationDelegate, UNUserNotificationCenterDel
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions:[UIApplication.LaunchOptionsKey: Any]?) -> Bool {
// Override point for customization after application launch.
_ = Guard.main // init guard
UIApplication.shared.registerForRemoteNotifications()
UNUserNotificationCenter.current().delegate = self

@ -67,9 +67,7 @@ class DataStore: ObservableObject {
StoreCenter.main.logsFailedAPICalls()
var synchronized: Bool = true
_ = Guard.main // init
#if DEBUG
if let sync = PListReader.readBool(plist: "local", key: "synchronized") {
synchronized = sync

Loading…
Cancel
Save