Skip to content

Commit

Permalink
Update Handler.php
Browse files Browse the repository at this point in the history
rollback changes for shutfdown handler
  • Loading branch information
christopheg authored May 27, 2021
1 parent fbfe875 commit 740a11a
Showing 1 changed file with 1 addition and 11 deletions.
12 changes: 1 addition & 11 deletions lib/Skeleton/Error/Handler.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,6 @@ class Handler {
*/
private $is_registered = false;

/**
* Error reporting
*
* @var int $error_reporting
*/
private $error_reporting = false;

/**
* Enable the error handler, assuming defaults
*/
Expand All @@ -62,9 +55,6 @@ public function register() {
return;
}

$this->error_reporting = error_reporting();
error_reporting(0);

// Automatically use sentry/sentry if detected
if ($this->detected_sentry_raven() === true && Config::$sentry_dsn !== null) {
$this->add_handler(new Handler\SentryRaven());
Expand Down Expand Up @@ -186,7 +176,7 @@ public function handle_exception($exception) {
* @return bool
*/
public function handle_error($level, $message, $file = null, $line = null) {
if ($level & $this->error_reporting) {
if ($level & error_reporting()) {
if ($this->is_silenced($file)) {
return true;
}
Expand Down

0 comments on commit 740a11a

Please sign in to comment.