mirror of
https://codeberg.org/OpenTracksApp/OpenTracks.git
synced 2026-10-03 01:53:05 +02:00
Bugfix: crash if heart rate sensor was null (i.e., preference not initialized).
This commit is contained in:
@@ -147,7 +147,7 @@ public class BluetoothLePreference extends DialogPreference {
|
||||
|
||||
BluetoothLePreference preference = (BluetoothLePreference) getPreference();
|
||||
String deviceSelected = preference.getValue();
|
||||
if (!deviceNone.equals(deviceSelected)) {
|
||||
if (deviceSelected != null && !deviceNone.equals(deviceSelected)) {
|
||||
listAdapter.add(preference.getValue(), preference.getValue());
|
||||
selectedEntryIndex = 1;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user