diff --git a/dibi/libs/DibiConnection.php b/dibi/libs/DibiConnection.php index 179231fb..38e2d964 100644 --- a/dibi/libs/DibiConnection.php +++ b/dibi/libs/DibiConnection.php @@ -118,7 +118,7 @@ class DibiConnection extends DibiObject $this->onEvent[] = array(new DibiFirePhpLogger($filter), 'logEvent'); } - if (class_exists('DibiNettePanel')) { + if (class_exists('DibiNettePanel', FALSE)) { $panel = new DibiNettePanel(isset($profilerCfg['explain']) ? $profilerCfg['explain'] : TRUE, $filter); $panel->register($this); } diff --git a/dibi/libs/DibiDataSource.php b/dibi/libs/DibiDataSource.php index bb700196..a50f9fcd 100644 --- a/dibi/libs/DibiDataSource.php +++ b/dibi/libs/DibiDataSource.php @@ -287,11 +287,11 @@ class DibiDataSource extends DibiObject implements IDataSource { try { return $this->connection->translate(' - SELECT %n', (empty($this->cols) ? '*' : $this->cols), ' - FROM %SQL', $this->sql, ' - %ex', $this->conds ? array('WHERE %and', $this->conds) : NULL, ' - %ex', $this->sorting ? array('ORDER BY %by', $this->sorting) : NULL, ' - %ofs %lmt', $this->offset, $this->limit +SELECT %n', (empty($this->cols) ? '*' : $this->cols), ' +FROM %SQL', $this->sql, ' +%ex', $this->conds ? array('WHERE %and', $this->conds) : NULL, ' +%ex', $this->sorting ? array('ORDER BY %by', $this->sorting) : NULL, ' +%ofs %lmt', $this->offset, $this->limit ); } catch (Exception $e) { trigger_error($e->getMessage(), E_USER_ERROR);