We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1e49c99 commit 64de0fbCopy full SHA for 64de0fb
1 file changed
phira/src/charts_view.rs
@@ -278,11 +278,10 @@ impl ChartsView {
278
},
279
Arc::clone(&self.icons),
280
self.rank_icons.clone(),
281
- get_data()
282
- .charts
283
- .iter()
284
- .find(|it| Some(&it.local_path) == download_path.as_ref())
285
- .map(|it| it.mods)
+ chart
+ .local_path
+ .as_ref()
+ .and_then(|path| get_data().charts.iter().find(|it| &it.local_path == path).map(|it| it.mods))
286
.unwrap_or_default(),
287
);
288
self.transit = Some(TransitState {
0 commit comments