diff options
Diffstat (limited to 'lib/Travelynx/Controller')
-rwxr-xr-x | lib/Travelynx/Controller/Traveling.pm | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/Travelynx/Controller/Traveling.pm b/lib/Travelynx/Controller/Traveling.pm index f0f1879..c8f975f 100755 --- a/lib/Travelynx/Controller/Traveling.pm +++ b/lib/Travelynx/Controller/Traveling.pm @@ -803,10 +803,14 @@ sub add_journey_form { $opt{rt_departure} //= $opt{sched_departure}; $opt{rt_arrival} //= $opt{sched_arrival}; - for my $key (qw(dep_station arr_station cancelled comment)) { + for my $key (qw(dep_station arr_station route cancelled comment)) { $opt{$key} = $self->param($key); } + if ( $opt{route} ) { + $opt{route} = [ split( qr{\r?\n\r?}, $opt{route} ) ]; + } + my $db = $self->pg->db; my $tx = $db->begin; |