Browse Source

docs: fix duplicate words in security module docstrings

Fix typos with repeated words in docstrings across the security module:
- "to to subclass" → "to subclass" in HTTPDigest and OpenIdConnect
- "that that it is" → "that it is" in OAuth2PasswordRequestForm and
  OAuth2PasswordRequestFormStrict

Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
pull/15119/head
N3XT3R1337 4 months ago
parent
commit
b56eff5709
  1. 2
      fastapi/security/http.py
  2. 4
      fastapi/security/oauth2.py
  3. 2
      fastapi/security/open_id_connect_url.py

2
fastapi/security/http.py

@ -321,7 +321,7 @@ class HTTPDigest(HTTPBase):
HTTP Digest authentication.
**Warning**: this is only a stub to connect the components with OpenAPI in FastAPI,
but it doesn't implement the full Digest scheme, you would need to to subclass it
but it doesn't implement the full Digest scheme, you would need to subclass it
and implement it in your code.
Ref: https://datatracker.ietf.org/doc/html/rfc7616

4
fastapi/security/oauth2.py

@ -53,7 +53,7 @@ class OAuth2PasswordRequestForm:
You could have custom internal logic to separate it by colon characters (`:`) or
similar, and get the two parts `items` and `read`. Many applications do that to
group and organize permissions, you could do it as well in your application, just
know that that it is application specific, it's not part of the specification.
know that it is application specific, it's not part of the specification.
"""
def __init__(
@ -207,7 +207,7 @@ class OAuth2PasswordRequestFormStrict(OAuth2PasswordRequestForm):
You could have custom internal logic to separate it by colon characters (`:`) or
similar, and get the two parts `items` and `read`. Many applications do that to
group and organize permissions, you could do it as well in your application, just
know that that it is application specific, it's not part of the specification.
know that it is application specific, it's not part of the specification.
grant_type: the OAuth2 spec says it is required and MUST be the fixed string "password".

2
fastapi/security/open_id_connect_url.py

@ -15,7 +15,7 @@ class OpenIdConnect(SecurityBase):
**Warning**: this is only a stub to connect the components with OpenAPI in FastAPI,
but it doesn't implement the full OpenIdConnect scheme, for example, it doesn't use
the OpenIDConnect URL. You would need to to subclass it and implement it in your
the OpenIDConnect URL. You would need to subclass it and implement it in your
code.
"""

Loading…
Cancel
Save