From 4d03c038e4c97feb2cfae7a28df81d11e1cf79fd Mon Sep 17 00:00:00 2001 From: David Cook Date: Thu, 9 Nov 2023 01:57:33 +0000 Subject: [PATCH] Bug 18317: Perl tidy Signed-off-by: David Nind Signed-off-by: Kyle M Hall Signed-off-by: Martin Renvoize Signed-off-by: Katrin Fischer --- C4/SIP/ILS.pm | 10 ++++++---- C4/SIP/ILS/Transaction/Checkout.pm | 6 ++++-- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/C4/SIP/ILS.pm b/C4/SIP/ILS.pm index e3bbedebb8..98422460d6 100644 --- a/C4/SIP/ILS.pm +++ b/C4/SIP/ILS.pm @@ -20,7 +20,7 @@ use C4::SIP::ILS::Transaction::Hold; use C4::SIP::ILS::Transaction::Renew; use C4::SIP::ILS::Transaction::RenewAll; -use C4::Context; #BZ 18317 +use C4::Context; #BZ 18317 my %supports = ( 'magnetic media' => 1, @@ -162,9 +162,11 @@ sub checkout { elsif ( !$item ) { $circ->screen_msg("Invalid Item"); } - elsif ( $item->{borrowernumber} - && ! C4::Context->preference('AllowItemsOnLoanCheckoutSIP') #BZ 18317 - && !_ci_cardnumber_cmp( $item->{borrowernumber}, $patron->borrowernumber ) ) + elsif ( + $item->{borrowernumber} + && !C4::Context->preference('AllowItemsOnLoanCheckoutSIP') #BZ 18317 + && !_ci_cardnumber_cmp( $item->{borrowernumber}, $patron->borrowernumber ) + ) { $circ->screen_msg("Item checked out to another patron"); } diff --git a/C4/SIP/ILS/Transaction/Checkout.pm b/C4/SIP/ILS/Transaction/Checkout.pm index 40165a9e53..b27fcbe4ff 100644 --- a/C4/SIP/ILS/Transaction/Checkout.pm +++ b/C4/SIP/ILS/Transaction/Checkout.pm @@ -88,9 +88,11 @@ sub do_checkout { { $self->screen_msg("Item is on hold for another patron."); $noerror = 0; - } elsif ($confirmation eq 'ISSUED_TO_ANOTHER' and C4::Context->preference("AllowItemsOnLoanCheckoutSIP")) { #BZ 18317 + } elsif ( $confirmation eq 'ISSUED_TO_ANOTHER' and C4::Context->preference("AllowItemsOnLoanCheckoutSIP") ) + { next; - } elsif ($confirmation eq 'ISSUED_TO_ANOTHER' and ! C4::Context->preference("AllowItemsOnLoanCheckoutSIP")) { #BZ 18317 + } elsif ( $confirmation eq 'ISSUED_TO_ANOTHER' and !C4::Context->preference("AllowItemsOnLoanCheckoutSIP") ) + { $self->screen_msg("Item already checked out to another patron. Please return item for check-in."); $noerror = 0; last; -- 2.39.5