Release Candidate Version 1.6
This commit is contained in:
@@ -79,6 +79,24 @@ class UserSettings: ObservableObject {
|
||||
}
|
||||
}
|
||||
|
||||
@Published var expandNutritionSection: Bool {
|
||||
didSet {
|
||||
UserDefaults.standard.set(expandNutritionSection, forKey: "expandNutritionSection")
|
||||
}
|
||||
}
|
||||
|
||||
@Published var expandKeywordSection: Bool {
|
||||
didSet {
|
||||
UserDefaults.standard.set(expandKeywordSection, forKey: "expandKeywordSection")
|
||||
}
|
||||
}
|
||||
|
||||
@Published var expandInfoSection: Bool {
|
||||
didSet {
|
||||
UserDefaults.standard.set(expandInfoSection, forKey: "expandInfoSection")
|
||||
}
|
||||
}
|
||||
|
||||
init() {
|
||||
self.username = UserDefaults.standard.object(forKey: "username") as? String ?? ""
|
||||
self.token = UserDefaults.standard.object(forKey: "token") as? String ?? ""
|
||||
@@ -91,6 +109,9 @@ class UserSettings: ObservableObject {
|
||||
self.storeImages = UserDefaults.standard.object(forKey: "storeImages") as? Bool ?? true
|
||||
self.storeThumb = UserDefaults.standard.object(forKey: "storeThumb") as? Bool ?? true
|
||||
self.lastUpdate = UserDefaults.standard.object(forKey: "lastUpdate") as? Date ?? Date.distantPast
|
||||
self.expandNutritionSection = UserDefaults.standard.object(forKey: "expandNutritionSection") as? Bool ?? false
|
||||
self.expandKeywordSection = UserDefaults.standard.object(forKey: "expandKeywordSection") as? Bool ?? false
|
||||
self.expandInfoSection = UserDefaults.standard.object(forKey: "expandInfoSection") as? Bool ?? false
|
||||
|
||||
if authString == "" {
|
||||
if token != "" && username != "" {
|
||||
|
||||
Reference in New Issue
Block a user