📝 Reflect latest changes
This commit is contained in:
parent
db329a8822
commit
c43d5030b9
1 changed files with 2 additions and 2 deletions
|
|
@ -141,8 +141,8 @@ async def list():
|
||||||
@router.get("/:id")
|
@router.get("/:id")
|
||||||
async def get(id: str):
|
async def get(id: str):
|
||||||
try:
|
try:
|
||||||
queryset = Tournament.get(pk=id)
|
tournament = await Tournament.get(pk=id)
|
||||||
return await Tournament.Schema.one(queryset)
|
return await Tournament.Schema.one.form_orm(tournament)
|
||||||
except DoesNotExist:
|
except DoesNotExist:
|
||||||
raise HTTPException(status_code=404, detail="item not found")
|
raise HTTPException(status_code=404, detail="item not found")
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue