fix: TipJar wallet access bug
This commit is contained in:
parent
4c77d6f11e
commit
d8e4237961
1 changed files with 2 additions and 2 deletions
|
|
@ -172,7 +172,7 @@ async def api_delete_tip(
|
||||||
raise HTTPException(
|
raise HTTPException(
|
||||||
status_code=HTTPStatus.NOT_FOUND, detail="No tip with this ID!"
|
status_code=HTTPStatus.NOT_FOUND, detail="No tip with this ID!"
|
||||||
)
|
)
|
||||||
if tip.wallet != g.wallet.id:
|
if tip.wallet != wallet.wallet.id:
|
||||||
raise HTTPException(
|
raise HTTPException(
|
||||||
status_code=HTTPStatus.FORBIDDEN,
|
status_code=HTTPStatus.FORBIDDEN,
|
||||||
detail="Not authorized to delete this tip!",
|
detail="Not authorized to delete this tip!",
|
||||||
|
|
@ -192,7 +192,7 @@ async def api_delete_tipjar(
|
||||||
raise HTTPException(
|
raise HTTPException(
|
||||||
status_code=HTTPStatus.NOT_FOUND, detail="No tipjar with this ID!"
|
status_code=HTTPStatus.NOT_FOUND, detail="No tipjar with this ID!"
|
||||||
)
|
)
|
||||||
if tipjar.wallet != g.wallet.id:
|
if tipjar.wallet != wallet.wallet.id:
|
||||||
|
|
||||||
raise HTTPException(
|
raise HTTPException(
|
||||||
status_code=HTTPStatus.FORBIDDEN,
|
status_code=HTTPStatus.FORBIDDEN,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue