Bug 29284: (follow-up) Fix code that I copied from too

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This commit is contained in:
Nick Clemens 2021-10-21 10:31:18 +00:00 committed by Jonathan Druart
parent 9cf301ac6f
commit 66683318ff
2 changed files with 8 additions and 2 deletions

View file

@ -507,7 +507,10 @@ eval {
};
if ($@ || $error) {
$template->param(query_error => $error.$@);
my $query_error = q{};
$query_error .= $error if $error;
$query_error .= $@ if $@;
$template->param(query_error => $query_error);
output_html_with_http_headers $cgi, $cookie, $template->output;
exit;
}

View file

@ -574,7 +574,10 @@ if ($tag) {
# use Data::Dumper; print STDERR "-" x 25, "\n", Dumper($results_hashref);
if (not $tag and ( $@ || $error)) {
$template->param(query_error => $error.$@);
my $query_error = q{};
$query_error .= $error if $error;
$query_error .= $@ if $@;
$template->param(query_error => $query_error);
output_html_with_http_headers $cgi, $cookie, $template->output;
exit;
}