From 5f4c8ef4ffb9ce32016571e7068c9fe2724ebf92 Mon Sep 17 00:00:00 2001 From: Nick Palmer Date: Thu, 24 Jan 2008 20:32:56 +0000 Subject: Move StartTrans() before the calls to LibertyXXX::store() so that rollback works right when something goes wrong in the content store. --- Pigeonholes.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Pigeonholes.php') diff --git a/Pigeonholes.php b/Pigeonholes.php index 61e4dbd..75e5acf 100644 --- a/Pigeonholes.php +++ b/Pigeonholes.php @@ -1,6 +1,6 @@ - * @version $Revision: 1.123 $ + * @version $Revision: 1.124 $ * @package pigeonholes */ @@ -645,9 +645,9 @@ class Pigeonholes extends LibertyAttachable { * @access public **/ function store( &$pParamHash ) { + $this->mDb->StartTrans(); if( $this->verify( $pParamHash ) && LibertyAttachable::store( $pParamHash ) ) { $table = BIT_DB_PREFIX."pigeonholes"; - $this->mDb->StartTrans(); // this really confusing, strange order way of saving items is due to strange behaviour of GenID // probably has to do with not null default nextval('public.liberty_structures_id_seq'::text) -- cgit v1.3