wallet/Shared/Defaults.swift

46 lines
1.2 KiB
Swift
Raw Normal View History

2021-11-30 15:56:00 +03:00
// Copyright © 2021 Tokenary. All rights reserved.
2021-06-20 19:50:24 +03:00
import Foundation
struct Defaults {
private static let userDefaults = UserDefaults.standard
2021-08-14 13:43:38 +03:00
static var latestReviewRequestDate: Date? {
get {
return userDefaults.value(forKey: "latestReviewRequestDate") as? Date
}
set {
userDefaults.set(newValue, forKey: "latestReviewRequestDate")
}
}
static var shouldPromptSafariForLegacyUsers: Bool {
get {
return userDefaults.bool(forKey: "shouldPromptSafariForLegacyUsers")
}
set {
userDefaults.set(newValue, forKey: "shouldPromptSafariForLegacyUsers")
}
}
2021-11-30 20:46:02 +03:00
static var didMigrateKeychainFromTokenaryV1: Bool {
get {
return userDefaults.bool(forKey: "didMigrateKeychainFromTokenaryV1")
}
set {
userDefaults.set(newValue, forKey: "didMigrateKeychainFromTokenaryV1")
}
}
2021-08-14 13:43:38 +03:00
static var reviewRequestsGoodMomentsCount: Int {
get {
return userDefaults.integer(forKey: "reviewRequestsGoodMomentsCount")
}
set {
userDefaults.set(newValue, forKey: "reviewRequestsGoodMomentsCount")
}
}
2021-06-20 19:50:24 +03:00
}