mirror of
https://codeberg.org/OpenTracksApp/OpenTracks.git
synced 2026-10-02 17:43:06 +02:00
Bugfix: unitSystem not loaded correctly.
Introduced in a5b44175a3
Fixes #1228.
This commit is contained in:
@@ -201,7 +201,7 @@ public class PreferencesUtils {
|
||||
|
||||
final String VALUE = getString(R.string.stats_units_key, STATS_UNIT_DEFAULT);
|
||||
return Arrays.stream(UnitSystem.values())
|
||||
.filter(d -> VALUE.equals(getString(d.getPreferenceId(), STATS_UNIT_DEFAULT)))
|
||||
.filter(d -> VALUE.equals(resources.getString(d.getPreferenceId(), STATS_UNIT_DEFAULT)))
|
||||
.findFirst()
|
||||
.orElse(UnitSystem.defaultUnitSystem()); //TODO This AGAIN defines the default
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user