Skip to content

Commit

Permalink
Fix issue with persisted data format
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeehut committed Jun 20, 2023
1 parent df9605e commit 1d36de0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Sources/ReviewKit/ReviewKit.swift
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public enum ReviewKit {
self.positiveEvents.append(PositiveEvent(date: Date(), weight: weight))
self.positiveEvents.removeAll { $0.date < Date().addingTimeInterval(.days(-self.criteria.eventsExpireAfterDays)) }

UserDefaults.standard.set(self.positiveEvents, forKey: "ReviewKit.positiveEvents")
UserDefaults.standard.set(self.positiveEvents.map(\.rawValue), forKey: "ReviewKit.positiveEvents")
}

static var positiveEvents: [PositiveEvent] = UserDefaults.standard
Expand Down

0 comments on commit 1d36de0

Please sign in to comment.