aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/db/postgres.php
diff options
context:
space:
mode:
Diffstat (limited to 'phpBB/includes/db/postgres.php')
-rw-r--r--phpBB/includes/db/postgres.php24
1 files changed, 7 insertions, 17 deletions
diff --git a/phpBB/includes/db/postgres.php b/phpBB/includes/db/postgres.php
index fbb113178a..3589f0c552 100644
--- a/phpBB/includes/db/postgres.php
+++ b/phpBB/includes/db/postgres.php
@@ -85,37 +85,27 @@ class dbal_postgres extends dbal
}
/**
- * sql transaction
+ * SQL Transaction
+ * @private
*/
- function sql_transaction($status = 'begin')
+ function _sql_transaction($status = 'begin')
{
switch ($status)
{
case 'begin':
- $result = @pg_query($this->db_connect_id, 'BEGIN');
- $this->transaction = true;
+ return @pg_query($this->db_connect_id, 'BEGIN');
break;
case 'commit':
- $result = @pg_query($this->db_connect_id, 'COMMIT');
- $this->transaction = false;
-
- if (!$result)
- {
- @pg_query($this->db_connect_id, 'ROLLBACK');
- }
+ return @pg_query($this->db_connect_id, 'COMMIT');
break;
case 'rollback':
- $result = @pg_query($this->db_connect_id, 'ROLLBACK');
- $this->transaction = false;
+ return @pg_query($this->db_connect_id, 'ROLLBACK');
break;
-
- default:
- $result = true;
}
- return $result;
+ return true;
}
/**