mirror of https://github.com/tiangolo/fastapi.git
fix for union
This commit is contained in:
parent
c7e6d8fba6
commit
ef3c5fa1f1
|
|
@ -88,7 +88,7 @@ async def read_required_dict_union(
|
|||
|
||||
|
||||
class QueryModelRequiredDictUnion(BaseModel):
|
||||
p: dict[str, str] | dict[str, int]
|
||||
p: Union[dict[str, str], dict[str, int]]
|
||||
|
||||
|
||||
@app.get("/model-required-dict-union")
|
||||
|
|
|
|||
Loading…
Reference in New Issue