Open MonGDCH opened 1 year ago
class A implements MiddlewareInterface { public function process(Request $request, callable $next): Response { $response = $next($request); $err = $response->exception(); if ($err) { var_dump($err->getMessage()); return response('err'); } return $response; } } class B implements MiddlewareInterface { public function process(Request $request, callable $next): Response { throw new \ErrorException('tes234t'); $response = $next($request); return $response; } }