Browse Source

improve formatting for and re-word doc string

pull/10589/head
Jan Vollmer 3 months ago
parent
commit
d70de472f6
No known key found for this signature in database GPG Key ID: 19473D3A5AB433DA
  1. 11
      fastapi/routing.py

11
fastapi/routing.py

@ -868,10 +868,13 @@ class APIRouter(routing.Router):
] = Default(generate_unique_id),
defer_init: Annotated[
bool,
Doc("""
By default every route will defer its initialization upon usage.
This flag disables the behavior for the routes defined in this router, causing the routes to initialize immediately.
"""),
Doc(
"""
By default, every route will defer its initialization until the first call.
This flag can be used to deactivate this behavior for the routes defined in this router,
causing the routes to initialize immediately when they are defined.
"""
),
] = True,
) -> None:
super().__init__(

Loading…
Cancel
Save