summaryrefslogtreecommitdiff
path: root/lib/Travelynx/Model/Stations.pm
diff options
context:
space:
mode:
authorBirte Kristina Friesel <derf@finalrewind.org>2025-06-18 22:26:53 +0200
committerBirte Kristina Friesel <derf@finalrewind.org>2025-06-18 22:26:53 +0200
commit0516ff89e688b1e305e674d3e4ced4207b250b9b (patch)
tree9a16d4d0cba804693aeb299b7f7916c4d1c83d1c /lib/Travelynx/Model/Stations.pm
parent7b0d8eda83cc03fca8b4228fb14795433c40f6dc (diff)
Stations->add_or_update: show user-friendly error if latlon are missing2.14.12
This can happen with EFA SEV stops
Diffstat (limited to 'lib/Travelynx/Model/Stations.pm')
-rw-r--r--lib/Travelynx/Model/Stations.pm3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/Travelynx/Model/Stations.pm b/lib/Travelynx/Model/Stations.pm
index bf35d1a..c6d9730 100644
--- a/lib/Travelynx/Model/Stations.pm
+++ b/lib/Travelynx/Model/Stations.pm
@@ -205,6 +205,9 @@ sub add_or_update {
);
return;
}
+ if (not $stop->latlon) {
+ die('Backend Error: Stop "' . $stop->full_name . '" has no geo coordinates');
+ }
$opt{db}->insert(
'stations',
{