Commit b449f2a
committed
fix(appList): use active filterType from uiState instead of stale _rawState
When updating app list filters, AppListViewModel previously read the
current FilterType from _rawState.value. Since _rawState contains raw
metadata (e.g. apps lists, loading/privilege flags) and does not update
when preferences are modified, its filterType remained stuck at the
default (FilterType.Source). As a result, when state filters (like
'Frozen') were selected, they were incorrectly persisted in DataStore
as source filters, resulting in query mismatches and showing an empty list.
Reading from uiState.value.filterType ensures the current user-selected
filter type is retrieved and stored correctly.1 parent 0e2e3d9 commit b449f2a
2 files changed
Lines changed: 5 additions & 6 deletions
File tree
- app/src/main/java/com/valhalla/thor/presentation/appList
Lines changed: 1 addition & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
284 | 284 | | |
285 | 285 | | |
286 | 286 | | |
287 | | - | |
288 | | - | |
| 287 | + | |
289 | 288 | | |
290 | 289 | | |
291 | 290 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
49 | | - | |
| 49 | + | |
50 | 50 | | |
51 | | - | |
52 | | - | |
53 | | - | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
0 commit comments