diff options
| author | Nick Palmer <nick@sluggardy.net> | 2008-01-24 20:32:56 +0000 |
|---|---|---|
| committer | Nick Palmer <nick@sluggardy.net> | 2008-01-24 20:32:56 +0000 |
| commit | 5f4c8ef4ffb9ce32016571e7068c9fe2724ebf92 (patch) | |
| tree | b169fc407b07abf005c8e8e9d2e2858047898279 | |
| parent | b3ba9721fbc393ac51895034325770c08632701e (diff) | |
| download | pigeonholes-5f4c8ef4ffb9ce32016571e7068c9fe2724ebf92.tar.gz pigeonholes-5f4c8ef4ffb9ce32016571e7068c9fe2724ebf92.tar.bz2 pigeonholes-5f4c8ef4ffb9ce32016571e7068c9fe2724ebf92.zip | |
Move StartTrans() before the calls to LibertyXXX::store() so that rollback works right when something goes wrong in the content store.
| -rw-r--r-- | Pigeonholes.php | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Pigeonholes.php b/Pigeonholes.php index 61e4dbd..75e5acf 100644 --- a/Pigeonholes.php +++ b/Pigeonholes.php @@ -1,6 +1,6 @@ <?php /** - * @version $Header: /cvsroot/bitweaver/_bit_pigeonholes/Pigeonholes.php,v 1.123 2007/12/12 11:58:23 nickpalmer Exp $ + * @version $Header: /cvsroot/bitweaver/_bit_pigeonholes/Pigeonholes.php,v 1.124 2008/01/24 20:32:56 nickpalmer Exp $ * * +----------------------------------------------------------------------+ * | Copyright ( c ) 2004, bitweaver.org @@ -17,7 +17,7 @@ * Pigeonholes class * * @author xing <xing@synapse.plus.com> - * @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) |
