From 311c029bcf0efe6abd2881e5e8bf0a5b533491b0 Mon Sep 17 00:00:00 2001 From: Michael Date: Mon, 24 Apr 2017 06:26:49 +0000 Subject: [PATCH] Rearranged lines --- include/dba.php | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/include/dba.php b/include/dba.php index ee62d309c..d9ab38f42 100644 --- a/include/dba.php +++ b/include/dba.php @@ -467,6 +467,22 @@ class dba { return $id; } + function __destruct() { + if ($this->db) { + switch ($this->driver) { + case 'pdo': + $this->db = null; + break; + case 'mysqli': + $this->db->close(); + break; + case 'mysql': + mysql_close($this->db); + break; + } + } + } + /** * @brief Replaces ANY_VALUE() function by MIN() function, * if the database server does not support ANY_VALUE(). @@ -487,22 +503,6 @@ class dba { return $sql; } - function __destruct() { - if ($this->db) { - switch ($this->driver) { - case 'pdo': - $this->db = null; - break; - case 'mysqli': - $this->db->close(); - break; - case 'mysql': - mysql_close($this->db); - break; - } - } - } - /** * @brief Executes a prepared statement *