Bug 39875: Dont show history check
Unless there is a cardnumber or an authenticated user Test plan: 1) Apply only the the tests file highlighting the issue: prove t/db_dependent/Koha/ILL/Request/Workflow/HistoryCheck.t 2) Notice it fails. 3) Apply this patch. 4) Run tests again. Notice it passes. Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Lin Wei Li <lin-wei.li@inLibro.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
This commit is contained in:
parent
ae2e9e23de
commit
6a0fcefa22
|
|
@ -193,9 +193,11 @@ sub _find_matching_requests {
|
|||
@existing_id_fields = grep { $_ eq 'pubmedid' } @existing_id_fields;
|
||||
}
|
||||
|
||||
my $patron = Koha::Patrons->find(
|
||||
{ cardnumber => $self->{metadata}->{cardnumber} || C4::Context->userenv->{'cardnumber'} } );
|
||||
my $cardnumber =
|
||||
$self->{metadata}->{cardnumber} || ( C4::Context->userenv && C4::Context->userenv->{'cardnumber'} );
|
||||
return 0 unless $cardnumber;
|
||||
|
||||
my $patron = Koha::Patrons->find( { cardnumber => $cardnumber } );
|
||||
return 0 unless $patron;
|
||||
|
||||
my $query;
|
||||
|
|
|
|||
Loading…
Reference in New Issue