Skip to content

Comments

🔧 Fix Type hint of auto_error which does not need to be Optional[bool]#4933

Merged
tiangolo merged 1 commit intofastapi:masterfrom
DavidKimDY:patch-1
Aug 26, 2022
Merged

🔧 Fix Type hint of auto_error which does not need to be Optional[bool]#4933
tiangolo merged 1 commit intofastapi:masterfrom
DavidKimDY:patch-1

Conversation

@DavidKimDY
Copy link
Contributor

Default is True and If someone doesn't want auto_error option, then it should be False instead of None.
I guess It is more Pythonic.

Default is True and If someone doesn't want auto_error option, then it should be False instead of None.  I guess It is more Pythonic.
@codecov
Copy link

codecov bot commented May 20, 2022

Codecov Report

Merging #4933 (705b243) into master (1876ebc) will not change coverage.
The diff coverage is n/a.

@@            Coverage Diff            @@
##            master     #4933   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          532       532           
  Lines        13672     13672           
=========================================
  Hits         13672     13672           
Impacted Files Coverage Δ
fastapi/security/oauth2.py 100.00% <ø> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1876ebc...705b243. Read the comment docs.

@github-actions
Copy link
Contributor

📝 Docs preview for commit 705b243 at: https://62876934334bfc3cf10a3aaa--fastapi.netlify.app

@DavidKimDY DavidKimDY changed the title No need to be Optional[bool] to auto_error 🔧No need to be Optional[bool] to auto_error May 20, 2022
@DavidKimDY DavidKimDY changed the title 🔧No need to be Optional[bool] to auto_error 🔧 Fix Type hint of auto_error which does not need to be Optional[bool] May 20, 2022
@tiangolo tiangolo changed the title 🔧 Fix Type hint of auto_error which does not need to be Optional[bool] 🔧 Fix Type hint of auto_error which does not need to be Optional[bool] Aug 26, 2022
@tiangolo
Copy link
Member

Good catch, thanks @DavidKimDY! 🚀 😎

@tiangolo tiangolo merged commit 0539dd9 into fastapi:master Aug 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants