[open-ils-commits] r17981 - branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application (erickson)

svn at svn.open-ils.org svn at svn.open-ils.org
Fri Sep 24 19:07:01 EDT 2010


Author: erickson
Date: 2010-09-24 19:07:00 -0400 (Fri, 24 Sep 2010)
New Revision: 17981

Modified:
   branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application/Booking.pm
Log:
more transaction cleanups

Modified: branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application/Booking.pm
===================================================================
--- branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application/Booking.pm	2010-09-24 23:04:45 UTC (rev 17980)
+++ branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application/Booking.pm	2010-09-24 23:07:00 UTC (rev 17981)
@@ -1291,12 +1291,13 @@
     }) or return $e->die_event;
 
     if (@$rows < 1) {
+        $e->rollback;
         return $rows;
     } else {
         # More than one result might be possible, but we don't want to return
         # more than one at this time.
         my $id = $rows->[0]->{"id"};
-        return $e->retrieve_booking_reservation([
+        my $resp =$e->retrieve_booking_reservation([
             $id, {
                 "flesh" => 2,
                 "flesh_fields" => {
@@ -1305,6 +1306,8 @@
                 }
             }
         ]) or $e->die_event;
+        $e->rollback;
+        return $resp;
     }
 }
 



More information about the open-ils-commits mailing list