fix CLogger bug #1555

Closed
wants to merge 1 commit into from

2 participants

@Ryadnov

if call Yii::app()->db->getStats() we get error

Invalid argument supplied for foreach()
/framework/logging/CLogger.php(194)

because $this->_except is null

@samdark http://yiiframework.ru/forum/viewtopic.php?f=6&t=8777

@samdark samdark was assigned Oct 10, 2012
@samdark
Yii Software LLC member

Need your config to reproduce.

@samdark
Yii Software LLC member

To reproduce:

  1. Enable DB profiling via 'enableProfiling' => true in db config. 2.
Yii::app()->db->createCommand("SELECT 1")->execute();
print_r(Yii::app()->db->getStats());

It doesn't matter if log component is configured or not.

@samdark samdark added a commit that closed this pull request Oct 11, 2012
@samdark samdark Fixes #1555 196bc5e
@samdark samdark closed this in 196bc5e Oct 11, 2012
@samdark
Yii Software LLC member

Thanks for finding this one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment