summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlsces <lester@lsces.co.uk>2012-10-01 10:45:51 +0100
committerlsces <lester@lsces.co.uk>2012-10-01 10:45:51 +0100
commit931d1bfacb3cf7b19d8fda100e67aeb8c13862e0 (patch)
tree6946e8410ab214abca0966a7094d1a2f50471c89
parent39b9861e7e517a7e990377ef979bffb27a3ec602 (diff)
downloadnexus-931d1bfacb3cf7b19d8fda100e67aeb8c13862e0.tar.gz
nexus-931d1bfacb3cf7b19d8fda100e67aeb8c13862e0.tar.bz2
nexus-931d1bfacb3cf7b19d8fda100e67aeb8c13862e0.zip
Thought that this would fix an open transaction on Firebird, but something else
seems to have started a transaction when building nexus menues, so commit in CompleteTransaction is not actioned until page closes
-rw-r--r--Nexus.php2
1 files changed, 2 insertions, 0 deletions
diff --git a/Nexus.php b/Nexus.php
index 9d4c041..843b857 100644
--- a/Nexus.php
+++ b/Nexus.php
@@ -236,6 +236,7 @@ class Nexus extends NexusSystem {
function storeMenu( &$pParamHash ) {
$ret = FALSE;
if( $this->verifyMenu( $pParamHash ) ) {
+ $this->mDb->StartTrans();
if( !@BitBase::verifyId( $pParamHash['menu_id'] ) ) {
$query = "INSERT INTO `".BIT_DB_PREFIX."nexus_menus`( `title`,`description`,`menu_type`,`plugin_guid`,`editable` ) VALUES(?,?,?,?,?)";
$result = $this->mDb->query( $query, array( $pParamHash['title'], $pParamHash['description'], $pParamHash['menu_type'], $pParamHash['plugin_guid'], $pParamHash['editable'] ) );
@@ -246,6 +247,7 @@ class Nexus extends NexusSystem {
$result = $this->mDb->query( $query, array( $pParamHash['title'], $pParamHash['description'], $pParamHash['menu_type'], $pParamHash['plugin_guid'], $pParamHash['editable'], $pParamHash['menu_id'] ) );
$ret = $pParamHash['menu_id'];
}
+ $this->mDb->CompleteTrans();
$this->writeMenuCache( $ret );
} else {
error_log( "Error storing menu: " . vc($this->mErrors) );