From 624dcb4f67a3ce4917ed1260724c8d33138f7def Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Wed, 13 Nov 2024 12:14:50 +0100 Subject: [PATCH] Bug 38299: (follow-up) (discussion) Move failure into same level --- C4/Installer.pm | 2 +- installer/data/mysql/updatedatabase.pl | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/C4/Installer.pm b/C4/Installer.pm index e70b0142a33..4dfebbf7fe9 100644 --- a/C4/Installer.pm +++ b/C4/Installer.pm @@ -743,8 +743,8 @@ sub run_db_rev { ); } catch { - say_failure( $outfh, "ERROR: " . $_ ); $error = $_; + say_failure( $outfh, "ERROR: " . $error ); }; close $outfh; diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index f4f43a89c0d..b4a276d05d8 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -24302,7 +24302,6 @@ unless ( $ENV{HTTP_HOST} ) { # Is that correct? } for my $e ( @{ $report->{error} } ) { say Encode::encode_utf8(join "\n", @{$e->{output}}); - #say_failure( undef, Encode::encode_utf8("ERROR - " . $e->{error}) ); $error_code = 1; } @@ -24313,7 +24312,6 @@ unless ( $ENV{HTTP_HOST} ) { # Is that correct? } for my $e ( @{ $report->{error} } ) { say Encode::encode_utf8(join "\n", @{$e->{output}}); - #say_failure( undef, Encode::encode_utf8("ERROR - " . $e->{error}) ); $error_code = 1; } exit $error_code; -- 2.34.1