public setupLogging ( Cake\Event\Event $event ) : void | ||
$event | Cake\Event\Event | Event |
Résultat | void |
public function setupLogging(Event $event)
{
foreach ($this->_getSources() as $connectionName) {
try {
$this->_getSource($connectionName)->logQueries(true);
$this->_getSource($connectionName)->logger(new QueryLogger());
} catch (MissingDatasourceConfigException $e) {
//Safe to ignore this :-)
}
}
}