You would want to use a callback handler.
$whoops = new WhoopsRun();
$handler = new WhoopsCallbackHandler(function($exception, $inspector, $run) {
//send an email
});
$whoops->pushHandler($handler)->register();
It looks like you are using use statement aliases so I matched your format, but the class is called Whoops\Handler\CallbackHandler.
reference : http://stackoverflow.com/questions/29281480/php-whoops-error-handler-email
沒有留言:
張貼留言