Merge pull request #8436 from yiisoft/exception-logging

log the whole exception object to allow log targets to work with it
This commit is contained in:
Qiang Xue
2015-05-15 22:44:56 -04:00
2 changed files with 2 additions and 1 deletions

View File

@ -10,6 +10,7 @@ Yii Framework 2 Change Log
- Enh #8070: `yii\console\controllers\MessageController` now sorts created messages, even if there is no new one, while saving to PHP file (klimov-paul) - Enh #8070: `yii\console\controllers\MessageController` now sorts created messages, even if there is no new one, while saving to PHP file (klimov-paul)
- Enh #8286: `yii\console\controllers\MessageController` improved allowing extraction of nested translator calls (klimov-paul) - Enh #8286: `yii\console\controllers\MessageController` improved allowing extraction of nested translator calls (klimov-paul)
- Enh #8415: `yii\helpers\Html` allows correct rendering of conditional comments containing `!IE` (salaros, klimov-paul) - Enh #8415: `yii\helpers\Html` allows correct rendering of conditional comments containing `!IE` (salaros, klimov-paul)
- Chg #6354: `ErrorHandler::logException()` will now log the whole exception object instead of only its string representation (cebe)
2.0.4 May 10, 2015 2.0.4 May 10, 2015

View File

@ -215,7 +215,7 @@ abstract class ErrorHandler extends Component
} elseif ($exception instanceof \ErrorException) { } elseif ($exception instanceof \ErrorException) {
$category .= ':' . $exception->getSeverity(); $category .= ':' . $exception->getSeverity();
} }
Yii::error((string) $exception, $category); Yii::error($exception, $category);
} }
/** /**