From bc25dc8b3e998b7d2a9404b53d908017ee7f5d40 Mon Sep 17 00:00:00 2001 From: miker Date: Wed, 3 Jun 2009 00:43:11 +0000 Subject: [PATCH] regression in hold targeting where blanket expire_time is set git-svn-id: svn://svn.open-ils.org/ILS/branches/rel_1_4_0@13292 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- .../src/perlmods/OpenILS/Application/Storage/Publisher/action.pm | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/action.pm b/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/action.pm index 45bebdd366..b81032d982 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/action.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/action.pm @@ -883,9 +883,11 @@ sub new_hold_copy_targeter { if ($hold->expire_time) { my $ex_time = $parser->parse_datetime( clense_ISO8601( $hold->expire_time ) ); - $hold->update( { cancel_time => 'now' } ) if ( DateTime->compare($ex_time, DateTime->now) < 0 ); - $self->method_lookup('open-ils.storage.transaction.commit')->run; - die "OK\n"; + if ( DateTime->compare($ex_time, DateTime->now) < 0 ) { + $hold->update( { cancel_time => 'now' } ); + $self->method_lookup('open-ils.storage.transaction.commit')->run; + die "OK\n"; + } } my $all_copies = []; -- 2.11.0