ui: only show high severity warnings in-app for 1.70 (#444)

As discussed with @barnstar, let's hide health messages within the app's main screen unless they are high severity. Low and mid-severity messages will be re-added in a more subtle, later iteration with a dedicated health messages view.

Signed-off-by: Andrea Gottardo <andrea@gottardo.me>
pull/446/head
Andrea Gottardo 4 months ago committed by GitHub
parent 26b4635c11
commit ca91191cc6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -125,7 +125,9 @@ class MainViewModel : IpnViewModel() {
viewModelScope.launch {
App.get().healthNotifier?.currentWarnings?.collect { warnings ->
healthWarnings.set(warnings.sorted())
healthWarnings.set(warnings
.filter { it.Severity == Health.Severity.high }
.sorted())
}
}
}

Loading…
Cancel
Save