@@ -, +, @@ --- acqui/lateorders.pl | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) --- a/acqui/lateorders.pl +++ a/acqui/lateorders.pl @@ -111,12 +111,12 @@ if ($op and $op eq "send_alert"){ } }; - if ( $@ ) { - $template->param(error_claim => $@); - } elsif ( ref $err and exists $err->{error} and $err->{error} eq "no_email" ) { + if ( ref $err and exists $err->{error} and $err->{error} eq "no_email" ) { $template->{VARS}->{'error_claim'} = "no_email"; } elsif ( ref $err and exists $err->{error} and $err->{error} eq "no_order_selected"){ $template->{VARS}->{'error_claim'} = "no_order_selected"; + } elsif ( $@ or ref $err and exists $err->{error} ) { + $template->param(error_claim => $@ || $err->{error}); } else { $template->{VARS}->{'info_claim'} = 1; } --