diff --git a/OLTListViewModel.swift b/OLTListViewModel.swift index faadd4e..e428d85 100644 --- a/OLTListViewModel.swift +++ b/OLTListViewModel.swift @@ -29,7 +29,7 @@ final class OLTListViewModel { do { let fetched = try await connection.olt.allStates() let names = (try? await connection.olt.nameMap()) ?? [:] - let merged = fetched + let merged: [OLTStateDoc] = fetched .map { olt in var olt = olt; olt.resolvedName = names[olt.id]; return olt } .sorted { $0.displayName.localizedCaseInsensitiveCompare($1.displayName) == .orderedAscending } guard gen == loadGeneration, !Task.isCancelled else { return } diff --git a/ONUListViewModel.swift b/ONUListViewModel.swift index f69371c..e0f1c43 100644 --- a/ONUListViewModel.swift +++ b/ONUListViewModel.swift @@ -42,7 +42,7 @@ final class ONUListViewModel { // Registration lives on OLT-STATE, operator names on ONU-CFG. Both best-effort. let registration = (try? await connection.olt.registrationMap()) ?? [:] let names = (try? await connection.onu.nameMap()) ?? [:] - let merged = fetched + let merged: [ONUStateDoc] = fetched .map { onu in var onu = onu onu.resolvedLifecycle = registration[onu.id]