Commit a47bf85e authored by Roman S. Borschel's avatar Roman S. Borschel

Fixed logging regression on Statements. Parameters bound via bindValue were lost.

parent ea008514
...@@ -123,7 +123,6 @@ class Statement implements DriverStatement ...@@ -123,7 +123,6 @@ class Statement implements DriverStatement
*/ */
public function execute($params = null) public function execute($params = null)
{ {
$this->_params = array();
$hasLogger = $this->_conn->getConfiguration()->getSQLLogger(); $hasLogger = $this->_conn->getConfiguration()->getSQLLogger();
if ($hasLogger) { if ($hasLogger) {
$queryStart = microtime(true); $queryStart = microtime(true);
...@@ -134,6 +133,7 @@ class Statement implements DriverStatement ...@@ -134,6 +133,7 @@ class Statement implements DriverStatement
if ($hasLogger) { if ($hasLogger) {
$this->_conn->getConfiguration()->getSQLLogger()->logSQL($this->_sql, $this->_params, microtime(true) - $queryStart); $this->_conn->getConfiguration()->getSQLLogger()->logSQL($this->_sql, $this->_params, microtime(true) - $queryStart);
} }
$this->_params = array();
return $stmt; return $stmt;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment