Skip to content

Commit

Permalink
return early after set error_reporting and display_errors ini set for…
Browse files Browse the repository at this point in the history
… exclude-php-errors settings
  • Loading branch information
samsonasik committed Apr 3, 2017
1 parent 058d24e commit 1287554
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/HeroTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -55,12 +55,12 @@ public function phpErrorHandler($errorType, $errorMessage, $errorFile, $errorLin
return;
}

if (! $this->errorHeroModuleConfig['display-settings']['display_errors'] ||
in_array($errorType, $this->errorHeroModuleConfig['display-settings']['exclude-php-errors'])
) {
if (! $this->errorHeroModuleConfig['display-settings']['display_errors']) {
error_reporting(E_ALL | E_STRICT);
ini_set('display_errors', 0);
}

if (in_array($errorType, $this->errorHeroModuleConfig['display-settings']['exclude-php-errors'])) {
return;
}

Expand Down

0 comments on commit 1287554

Please sign in to comment.