Fixing DboSource::execute() so it only logs when fullDebug is set to true

git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@3782 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
phpnut 2006-11-01 03:52:41 +00:00
parent b4306ac594
commit 29ba60481a

View file

@ -84,7 +84,7 @@ class DboSource extends DataSource {
$this->debug = DEBUG > 0; $this->debug = DEBUG > 0;
$this->fullDebug = DEBUG > 1; $this->fullDebug = DEBUG > 1;
parent::__construct($config); parent::__construct($config);
if ($autoConnect) { if ($autoConnect) {
return $this->connect(); return $this->connect();
} else { } else {
@ -265,7 +265,10 @@ class DboSource extends DataSource {
$this->took = round((getMicrotime() - $t) * 1000, 0); $this->took = round((getMicrotime() - $t) * 1000, 0);
$this->error = $this->lastError(); $this->error = $this->lastError();
$this->numRows = $this->lastNumRows($this->_result); $this->numRows = $this->lastNumRows($this->_result);
$this->logQuery($sql);
if($this->fullDebug) {
$this->logQuery($sql);
}
if ($this->error) { if ($this->error) {
return false; return false;