🎨 [pre-commit.ci] Auto format from pre-commit.com hooks

This commit is contained in:
pre-commit-ci[bot] 2025-08-09 20:06:58 +00:00
parent 5c48120af9
commit 3b19dee39d
1 changed files with 3 additions and 6 deletions

View File

@ -973,8 +973,7 @@ class FastAPI(Starlette):
self.exception_handlers: Dict[
Any, Callable[[Request, Any], Union[Response, Awaitable[Response]]]
] = {} if exception_handlers is None else dict(exception_handlers)
self.exception_handlers.setdefault(
HTTPException, http_exception_handler)
self.exception_handlers.setdefault(HTTPException, http_exception_handler)
self.exception_handlers.setdefault(
RequestValidationError, request_validation_exception_handler
)
@ -1052,8 +1051,7 @@ class FastAPI(Starlette):
swagger_ui_parameters=self.swagger_ui_parameters,
)
self.add_route(self.docs_url, swagger_ui_html,
include_in_schema=False)
self.add_route(self.docs_url, swagger_ui_html, include_in_schema=False)
if self.swagger_ui_oauth2_redirect_url:
@ -1299,8 +1297,7 @@ class FastAPI(Starlette):
self,
router: Annotated[routing.APIRouter, Doc("The `APIRouter` to include.")],
*,
prefix: Annotated[str, Doc(
"An optional path prefix for the router.")] = "",
prefix: Annotated[str, Doc("An optional path prefix for the router.")] = "",
tags: Annotated[
Optional[List[Union[str, Enum]]],
Doc(