mirror of
https://github.com/yiisoft/yii2.git
synced 2025-11-17 14:57:23 +08:00
Removed headers in ErrorHandler.
This commit is contained in:
@@ -90,6 +90,8 @@ class ErrorHandler extends Component
|
|||||||
$useErrorView = !YII_DEBUG || $exception instanceof UserException;
|
$useErrorView = !YII_DEBUG || $exception instanceof UserException;
|
||||||
|
|
||||||
$response = Yii::$app->getResponse();
|
$response = Yii::$app->getResponse();
|
||||||
|
$response->getHeaders()->removeAll();
|
||||||
|
|
||||||
if ($useErrorView && $this->errorAction !== null) {
|
if ($useErrorView && $this->errorAction !== null) {
|
||||||
$result = Yii::$app->runAction($this->errorAction);
|
$result = Yii::$app->runAction($this->errorAction);
|
||||||
if ($result instanceof Response) {
|
if ($result instanceof Response) {
|
||||||
|
|||||||
Reference in New Issue
Block a user