incognitolm commited on
Commit
c173974
·
verified ·
1 Parent(s): 5dda4a8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -6
app.py CHANGED
@@ -433,12 +433,7 @@ async def start_game(request: Request):
433
  async def delete_game(request: Request):
434
  data = await request.json()
435
  pin = data.get("pin")
436
- newPin = random.randint(100000, 999999)
437
- newGame = games.get(newPin)
438
-
439
- while newGame:
440
- newPin = random.randint(100000, 999999)
441
- newGame = games.get(newPin)
442
 
443
  if not pin:
444
  raise HTTPException(status_code=400, detail="PIN is required.")
 
433
  async def delete_game(request: Request):
434
  data = await request.json()
435
  pin = data.get("pin")
436
+ newPin = data.get("newPin")
 
 
 
 
 
437
 
438
  if not pin:
439
  raise HTTPException(status_code=400, detail="PIN is required.")