From 8b62a94e1e3b6a61030dd20982d50d017397e4e9 Mon Sep 17 00:00:00 2001 From: Birte Kristina Friesel Date: Sun, 19 Oct 2025 17:03:12 +0200 Subject: stats: no need for transactions here --- lib/Travelynx/Command/stats.pm | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'lib/Travelynx/Command/stats.pm') diff --git a/lib/Travelynx/Command/stats.pm b/lib/Travelynx/Command/stats.pm index 1ba1db9..214abfd 100644 --- a/lib/Travelynx/Command/stats.pm +++ b/lib/Travelynx/Command/stats.pm @@ -26,13 +26,12 @@ sub refresh_all { for my $user ( $db->select( 'users', ['id'], { status => 1 } )->hashes->each ) { - my $tx = $db->begin; $self->app->journeys->generate_missing_stats( uid => $user->{id} ); $self->app->journeys->get_stats( - uid => $user->{id}, - year => $now->year + uid => $user->{id}, + year => $now->year, + write_only => 1, ); - $tx->commit; if ( $i == $total or ( $i % 10 ) == 0 ) { printf( "%.f%% complete", $i * 100 / $total ); } -- cgit v1.2.3