From 441dddbaf8a05b2f617f8e47e2b861224ad2b212 Mon Sep 17 00:00:00 2001 From: Sergei Predvoditelev Date: Fri, 3 Apr 2026 11:23:59 +0300 Subject: [PATCH] Fix typo in handling-errors.md Fix #409 --- src/guide/runtime/handling-errors.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/guide/runtime/handling-errors.md b/src/guide/runtime/handling-errors.md index e62dda22..e2864681 100644 --- a/src/guide/runtime/handling-errors.md +++ b/src/guide/runtime/handling-errors.md @@ -82,14 +82,14 @@ use Yiisoft\Injector\Injector; return [ // ... - ErrorHandler::class => static function (ResponseFactoryInterface $responseFactory, Injector $injector) { + ExceptionResponder::class => static function (ResponseFactoryInterface $responseFactory, Injector $injector) { $exceptionMap = [ // Status code with which the factory creates the response. MyNotFoundException::class => 404, // PHP callable that must return a `Psr\Http\Message\ResponseInterface`. MyHttpException::class => static fn (MyHttpException $exception) => new MyResponse($exception), // ... - ], + ]; return new ExceptionResponder($exceptionMap, $responseFactory, $injector); },