diff options
author | Daniel Friesel <derf@finalrewind.org> | 2022-12-07 22:46:04 +0100 |
---|---|---|
committer | Daniel Friesel <derf@finalrewind.org> | 2022-12-07 22:46:04 +0100 |
commit | afedcef2663ceda6d4a9b88af702c04eb4eb0f4a (patch) | |
tree | ecd536a4c8678efca7a448485d173861ba40ed49 /lib/Travelynx.pm | |
parent | 73dd23e422397aeb4a0538e99b641c250f4e6250 (diff) |
get name/ds100 from db and lat/lon from dict1.28.1
result: significant performance improvement for stats generation
Diffstat (limited to 'lib/Travelynx.pm')
-rwxr-xr-x | lib/Travelynx.pm | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/lib/Travelynx.pm b/lib/Travelynx.pm index 8c98f15..8d661d2 100755 --- a/lib/Travelynx.pm +++ b/lib/Travelynx.pm @@ -323,12 +323,13 @@ sub startup { journeys => sub { my ($self) = @_; state $journeys = Travelynx::Model::Journeys->new( - log => $self->app->log, - pg => $self->pg, - in_transit => $self->in_transit, - stats_cache => $self->journey_stats_cache, - renamed_station => $self->app->renamed_station, - stations => $self->stations, + log => $self->app->log, + pg => $self->pg, + in_transit => $self->in_transit, + stats_cache => $self->journey_stats_cache, + renamed_station => $self->app->renamed_station, + latlon_by_station => $self->app->coordinates_by_station, + stations => $self->stations, ); } ); @@ -424,8 +425,7 @@ sub startup { my @unknown_stations; for my $station (@stations) { - my $station_info - = $self->stations->get_by_name( $station ); + my $station_info = $self->stations->get_by_name($station); if ( not $station_info ) { push( @unknown_stations, $station ); } |