Stabilize beta release with warning cleanup and edge-case fixes

This commit is contained in:
Trey t
2026-02-22 13:18:14 -06:00
parent fddea81e36
commit ec2bbb4764
55 changed files with 712 additions and 315 deletions

View File

@@ -54,12 +54,12 @@ final class ProgressViewModel {
/// Count of trips for the selected sport (stub - can be enhanced)
var tripCount: Int {
// TODO: Fetch saved trips count from SwiftData
0
savedTripCount
}
/// Recent visits sorted by date (cached, recomputed on data change)
private(set) var recentVisits: [VisitSummary] = []
private(set) var savedTripCount: Int = 0
// MARK: - Configuration
@@ -89,6 +89,7 @@ final class ProgressViewModel {
sortBy: [SortDescriptor(\.visitDate, order: .reverse)]
)
visits = try context.fetch(descriptor)
savedTripCount = try context.fetchCount(FetchDescriptor<SavedTrip>())
}
} catch {
self.error = error