From 745b3708d3f5a43e09a70616c164de45adf49daa Mon Sep 17 00:00:00 2001 From: Birte Kristina Friesel Date: Thu, 5 Oct 2023 06:06:08 +0200 Subject: [PATCH] frontend tvly_journey_progress: handle entry-only stops --- public/static/js/travelynx-actions.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/public/static/js/travelynx-actions.js b/public/static/js/travelynx-actions.js index 30f2439..437ad60 100644 --- a/public/static/js/travelynx-actions.js +++ b/public/static/js/travelynx-actions.js @@ -166,7 +166,11 @@ function tvly_journey_progress() { break; } if ((rt_dep != 0) && (rt_dep - now > 0)) { - $('.next-stop').html(stop_name + '
' + hhmm(rt_arr) + ' → ' + hhmm(rt_dep) + odelay(sched_dep, rt_dep)); + if (rt_arr != 0) { + $('.next-stop').html(stop_name + '
' + hhmm(rt_arr) + ' → ' + hhmm(rt_dep) + odelay(sched_dep, rt_dep)); + } else { + $('.next-stop').html(stop_name + '
' + hhmm(rt_dep) + odelay(sched_dep, rt_dep)); + } break; } }