From 2052e167f7dc04e37041443f640af4e8c18c3bc0 Mon Sep 17 00:00:00 2001
From: tbrehm <t.brehm@ispconfig.org>
Date: Tue, 04 Dec 2012 08:36:35 -0500
Subject: [PATCH] Fixed: FS#2524 - Add check in remote api that no email alias can be added that exists as mailbox
---
server/lib/classes/db_mysql.inc.php | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/server/lib/classes/db_mysql.inc.php b/server/lib/classes/db_mysql.inc.php
index 54561c0..4c75e62 100644
--- a/server/lib/classes/db_mysql.inc.php
+++ b/server/lib/classes/db_mysql.inc.php
@@ -103,7 +103,8 @@
}
public function query($queryString) {
- $this->queryId = parent::query($queryString);
+ parent::ping();
+ $this->queryId = parent::query($queryString);
$this->updateError('DB::query('.$queryString.') -> mysqli_query');
if(!$this->queryId) {
return false;
@@ -275,9 +276,9 @@
if($diff_num > 0) {
- $diffstr = $app->db->quote(serialize($diffrec_full));
+ $diffstr = $this->quote(serialize($diffrec_full));
if(isset($_SESSION)) {
- $username = $app->db->quote($_SESSION['s']['user']['username']);
+ $username = $this->quote($_SESSION['s']['user']['username']);
} else {
$username = 'admin';
}
@@ -287,7 +288,7 @@
if($action == 'UPDATE') $action = 'u';
if($action == 'DELETE') $action = 'd';
$sql = "INSERT INTO sys_datalog (dbtable,dbidx,server_id,action,tstamp,user,data) VALUES ('".$db_table."','$dbidx','$server_id','$action','".time()."','$username','$diffstr')";
- $app->db->query($sql);
+ $this->query($sql);
}
return true;
--
Gitblit v1.9.1