src/class/ShutdownHandler.php
public function handle() {
            if (ErrorHandler::isRegistered()) {
                $e = new Error(error_get_last());

                if (Error::shouldBeReported($e->getType())) {
                    $r = ErrorHandler::getLastReportedError();
                    $h = ErrorHandler::getLastRegisteredHandler();

                    if (!$e->isEmpty() && $h && ($r ? !$r->isEmpty() && !$r->equals($e) : true)) {
                        $h->handle($e->getType(),
                                   Alo::ifnull($e->getMessage(), '<<unknown error>>'),
                                   Alo::ifnull($e->getFile(), '<<unknown file>>'),
                                   Alo::ifnull($e->getLine(), '<<unknown line>>'));
                    }
                }
            }
        }
public function handle() {
            if (ErrorHandler::isRegistered()) {
                $e = new Error(error_get_last());

                if (Error::shouldBeReported($e->getType())) {
                    $r = ErrorHandler::getLastReportedError();
                    $h = ErrorHandler::getLastRegisteredHandler();

                    if (!$e->isEmpty() && $h && ($r ? !$r->isEmpty() && !$r->equals($e) : true)) {
                        $h->handle($e->getType(),
                                   Alo::ifnull($e->getMessage(), '<<unknown error>>'),
                                   Alo::ifnull($e->getFile(), '<<unknown file>>'),
                                   Alo::ifnull($e->getLine(), '<<unknown line>>'));
                    }
                }
            }
        }
public function handle ( ) { if ( ErrorHandler :: isRegistered ( ) ) { $ e = new Error ( error_get_last ( ) ) ; if ( Error :: shouldBeReported ( $ e -> getType ( ) ) ) { $ r = ErrorHandler :: getLastReportedError ( ) ; $ h = ErrorHandler :: getLastRegisteredHandler ( ) ; if ( ! $ e -> isEmpty ( ) && $ h && ( $ r ? ! $ r -> isEmpty ( ) && ! $ r -> equals ( $ e ) : true ) ) { $ h -> handle ( $ e -> getType ( ) , Alo :: ifnull ( $ e -> getMessage ( ) , '<<unknown error>>' ) , Alo :: ifnull ( $ e -> getFile ( ) , '<<unknown file>>' ) , Alo :: ifnull ( $ e -> getLine ( ) , '<<unknown line>>' ) ) ; } } } }
The shutdown handler

@author Art <a.molcanovas@gmail.com>
@since  1.2.1 Should now report fatal errors if no errors had been raised beforehand.
@codeCoverageIgnore
The shutdown handler