From 80a5a539e8e44d170b22f3e7768110aefdbe1990 Mon Sep 17 00:00:00 2001 From: Maurice Parker Date: Thu, 26 Sep 2019 14:29:00 -0500 Subject: [PATCH] Make it more clear that we are using shared defaults --- iOS/AppDefaults.swift | 2 +- iOS/AppDelegate.swift | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/iOS/AppDefaults.swift b/iOS/AppDefaults.swift index 3ef8572f5..dce1fdc19 100644 --- a/iOS/AppDefaults.swift +++ b/iOS/AppDefaults.swift @@ -10,7 +10,7 @@ import UIKit struct AppDefaults { - static var shared = UserDefaults.standard + static var shared = UserDefaults.init(suiteName: "group.\(Bundle.main.bundleIdentifier!)")! struct Key { static let lastImageCacheFlushDate = "lastImageCacheFlushDate" diff --git a/iOS/AppDelegate.swift b/iOS/AppDelegate.swift index 9a4757548..24561755b 100644 --- a/iOS/AppDelegate.swift +++ b/iOS/AppDelegate.swift @@ -56,7 +56,6 @@ class AppDelegate: UIResponder, UIApplicationDelegate, UISplitViewControllerDele // Force lazy initialization of the web view provider so that it can warm up the queue of prepared web views let _ = ArticleViewControllerWebViewProvider.shared AccountManager.shared = AccountManager() - AppDefaults.shared = UserDefaults.init(suiteName: "group.\(Bundle.main.bundleIdentifier!)")! registerBackgroundTasks()