Backup before friendly design pass
This commit is contained in:
@@ -60,7 +60,16 @@ enum MomentWidgetStorage {
|
||||
static let lastRecordedAtKey = "lastWidgetSnapshotDate"
|
||||
|
||||
static var defaults: UserDefaults {
|
||||
UserDefaults(suiteName: appGroupIdentifier) ?? .standard
|
||||
guard appGroupAvailable,
|
||||
let defaults = UserDefaults(suiteName: appGroupIdentifier) else {
|
||||
return .standard
|
||||
}
|
||||
|
||||
return defaults
|
||||
}
|
||||
|
||||
private static var appGroupAvailable: Bool {
|
||||
FileManager.default.containerURL(forSecurityApplicationGroupIdentifier: appGroupIdentifier) != nil
|
||||
}
|
||||
|
||||
static func enqueue(ratingRawValue: String) {
|
||||
|
||||
Reference in New Issue
Block a user