Skip to content

Commit abb00f1

Browse files
robhojohan12345
authored andcommitted
Fix app crash when downloading full charger list from data source
R.string.downloading_chargers_percent expects a Float argument, but an Int was supplied.
1 parent b57bb5d commit abb00f1

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

app/src/main/java/net/vonforst/evmap/fragment/MapFragment.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -654,7 +654,7 @@ class MapFragment : Fragment(), OnMapReadyCallback, MenuProvider {
654654
binding.progressBar2.isIndeterminate = res.progress == null
655655
binding.progressBar2.progress = ((res.progress ?: 0f) * 100f).toInt().coerceIn(0, 100)
656656
binding.search.hint = if (res.progress != null) {
657-
getString(R.string.downloading_chargers_percent, (res.progress * 100f).toInt())
657+
getString(R.string.downloading_chargers_percent, (res.progress * 100f))
658658
} else {
659659
getString(R.string.search)
660660
}

0 commit comments

Comments
 (0)