Use environment variable if parsed cli arg is None
This commit is contained in:
parent
0d751a69a7
commit
022e9ebcb8
1 changed files with 1 additions and 1 deletions
|
@ -40,7 +40,7 @@ if __name__ == "__main__":
|
|||
)
|
||||
|
||||
args = parser.parse_args()
|
||||
settings = Settings(**vars(args))
|
||||
settings = Settings(**{k: v for k, v in vars(args).items() if v is not None})
|
||||
app = create_app(settings=settings)
|
||||
|
||||
uvicorn.run(
|
||||
|
|
Loading…
Add table
Reference in a new issue