more devices

This commit is contained in:
2023-10-01 15:51:34 +02:00
parent 6f73f37eaa
commit 30d43d1fde
6 changed files with 61 additions and 3 deletions
+2 -2
View File
@@ -214,12 +214,12 @@ class RepaFieldView extends WatchUi.DataField {
} else {
timerState = Activity.TIMER_STATE_OFF;
}
if (info.distanceToDestination != null) {
if (info has :distanceToDestination && info.distanceToDestination != null) {
toDestination = info.distanceToDestination as Float;
} else {
toDestination = 0.0f;
}
if (info.offCourseDistance != null) {
if (info has :offCourseDistance && info.offCourseDistance != null) {
offCourse = info.offCourseDistance as Float;
} else {
offCourse = 0.0f;