Bug 36212: Add check on barcode before searching items
Test plan:
Add an item to your database that has no barcode.
Run t/db_dependent/Circulation.t
It will fail without this patch, pass with this patch.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 8413b37679
)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
This commit is contained in:
parent
b0660d11f5
commit
246566b7d1
1 changed files with 1 additions and 1 deletions
|
@ -327,7 +327,7 @@ sub transferbook {
|
|||
my $trigger = $params->{trigger};
|
||||
my $messages;
|
||||
my $dotransfer = 1;
|
||||
my $item = Koha::Items->find( { barcode => $barcode } );
|
||||
my $item = $barcode ? Koha::Items->find( { barcode => $barcode } ) : undef;
|
||||
|
||||
Koha::Exceptions::MissingParameter->throw(
|
||||
"Missing mandatory parameter: from_branch")
|
||||
|
|
Loading…
Reference in a new issue