[open-ils-commits] r13294 - trunk/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher (miker)

svn at svn.open-ils.org svn at svn.open-ils.org
Tue Jun 2 20:52:37 EDT 2009


Author: miker
Date: 2009-06-02 20:52:36 -0400 (Tue, 02 Jun 2009)
New Revision: 13294

Modified:
   trunk/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/action.pm
Log:
regression in hold targeting where blanket expire_time is set

Modified: trunk/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/action.pm
===================================================================
--- trunk/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/action.pm	2009-06-03 00:46:25 UTC (rev 13293)
+++ trunk/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/action.pm	2009-06-03 00:52:36 UTC (rev 13294)
@@ -892,9 +892,11 @@
 
 			if ($hold->expire_time) {
 				my $ex_time = $parser->parse_datetime( clense_ISO8601( $hold->expire_time ) );
-				$hold->update( { cancel_cause => 1, 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 = [];



More information about the open-ils-commits mailing list