mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-02 21:41:19 +08:00
Fix #16671: Logging in Connection::open() was not respecting Connection::$enableLogging
This commit is contained in:
@ -613,7 +613,10 @@ class Connection extends Component
|
||||
$token = 'Opening DB connection: ' . $this->dsn;
|
||||
$enableProfiling = $this->enableProfiling;
|
||||
try {
|
||||
Yii::info($token, __METHOD__);
|
||||
if ($this->enableLogging) {
|
||||
Yii::info($token, __METHOD__);
|
||||
}
|
||||
|
||||
if ($enableProfiling) {
|
||||
Yii::beginProfile($token, __METHOD__);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user