@@ -, +, @@ C4/Utils/DataTables/Members.pm - if $term !~ /^%/ - and $searchtype eq "contain"; + if (defined $searchtype) && $searchtype eq "contain" + && $term !~ /^%/; - Home -> Circulation -> Checkout - Search for a user that does not exist (I searched 'whywouldthisexist') on the intranet interface. - Look at the intranet logs - Apply the patch - Repeat the search - Sign off :-D --- C4/Utils/DataTables/Members.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/C4/Utils/DataTables/Members.pm +++ a/C4/Utils/DataTables/Members.pm @@ -76,8 +76,8 @@ sub search { $term .= '%' # end with anything if $term !~ /%$/; $term = "%$term" # begin with anythin unless start_with - if $term !~ /^%/ - and $searchtype eq "contain"; + if (defined $searchtype) && $searchtype eq "contain" + && $term !~ /^%/; my @where_strs_or; for my $searchfield ( split /,/, $searchfields->{$searchfieldstype} ) { push @where_strs_or, "borrowers." . $dbh->quote_identifier($searchfield) . " LIKE ?"; --