public function timeToDie()
    {
        $arr_error = error_get_last();
        if ($arr_error && in_array($arr_error['type'], [E_ERROR, E_USER_ERROR, E_COMPILE_ERROR])) {
            $this->jsonError(new \ErrorException($arr_error['message'], 500, 0, $arr_error['file'], $arr_error['line']), 500);
        }
    }
public function timeToDie()
    {
        $arr_error = error_get_last();
        if ($arr_error && in_array($arr_error['type'], [E_ERROR, E_USER_ERROR, E_COMPILE_ERROR])) {
            $this->jsonError(new \ErrorException($arr_error['message'], 500, 0, $arr_error['file'], $arr_error['line']), 500);
        }
    }
public function timeToDie ( ) { $ arr_error = error_get_last ( ) ; if ( $ arr_error && in_array ( $ arr_error [ 'type' ] , [ E_ERROR , E_USER_ERROR , E_COMPILE_ERROR ] ) ) { $ this -> jsonError ( new \ ErrorException ( $ arr_error [ 'message' ] , 500 , 0 , $ arr_error [ 'file' ] , $ arr_error [ 'line' ] ) , 500 ) ; } }
Custom shutdown function
Custom shutdown function