mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2025-02-17 21:06:48 +01:00
Avoid possible NPE
This commit is contained in:
parent
cfddba0e4d
commit
d3fd203c6c
@ -85,7 +85,11 @@ public class TimePreference extends DialogPreference {
|
|||||||
time = getPersistedString(defaultValue.toString());
|
time = getPersistedString(defaultValue.toString());
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
time = defaultValue.toString();
|
if (defaultValue != null) {
|
||||||
|
time = defaultValue.toString();
|
||||||
|
} else {
|
||||||
|
time = "00:00";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
String[] pieces = time.split(":");
|
String[] pieces = time.split(":");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user