Bug 37508: (QA follow-up) Move sth error check up
This patch moves the error check right before the ->check_columns call. This is how main and 24.05 behave. 23.11 doesn't have bug 35907 backported so things are not exactly the same. With this patch tests pass and the only difference in behavior is logging. Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This commit is contained in:
parent
e3d2c38a1f
commit
19d8d67cb4
1 changed files with 2 additions and 1 deletions
|
@ -615,11 +615,12 @@ sub execute_query {
|
|||
};
|
||||
warn $@ if $@;
|
||||
|
||||
return ( $sth, { queryerr => $sth->errstr } ) if ($sth->err);
|
||||
|
||||
# Check if table.* contained forbidden column names
|
||||
return ( $sth, { passworderr => "Illegal column in results" } )
|
||||
if Koha::Report->new->check_columns( undef, $sth->{NAME_lc} );
|
||||
|
||||
return ( $sth, { queryerr => $sth->errstr } ) if ($sth->err);
|
||||
return ( $sth );
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue