As discovered while testing the lost and paid feature, when closing earlier transactions where
the item is currently lost, it could change the item status to lost and paid prematurely.
Change the logic so that it only does this if the current transaction being closed either has
a status of lost or longoverdue.
Signed-off-by: Ben Shum <bshum@biblio.org>
Signed-off-by: Kathy Lussier <klussier@masslnc.org>
# check org_unit_settings for the copy owning library
# and adjust and possibly adjust copy status to lost
# and paid.
- if ($circ) {
+ if ($circ && ($circ->stop_fines eq 'LOST' || $circ->stop_fines eq 'LONGOVERDUE')) {
# We need the copy to check settings and to possibly
# change its status.
my $copy = $circ->target_copy();