Sync fastapi docs from 50fa3f7c on 2026-01-11
This commit is contained in:
@@ -14,7 +14,7 @@ app = FastAPI()
|
||||
|
||||
@app.post("/items/")
|
||||
async def create_item(item: Item):
|
||||
item_dict = item.dict()
|
||||
item_dict = item.model_dump()
|
||||
if item.tax is not None:
|
||||
price_with_tax = item.price + item.tax
|
||||
item_dict.update({"price_with_tax": price_with_tax})
|
||||
|
||||
Reference in New Issue
Block a user