🐛 Players now can also start quizzes from others
This commit is contained in:
@@ -81,7 +81,6 @@ async def start_quiz(quiz_id: str, user: User = Depends(get_current_user)):
|
|||||||
quiz = await Quiz.objects.get_or_none(id=quiz_id, public=True)
|
quiz = await Quiz.objects.get_or_none(id=quiz_id, public=True)
|
||||||
if quiz is None:
|
if quiz is None:
|
||||||
return JSONResponse(status_code=404, content={"detail": "quiz not found"})
|
return JSONResponse(status_code=404, content={"detail": "quiz not found"})
|
||||||
else:
|
|
||||||
game_pin = randint(10000000, 99999999)
|
game_pin = randint(10000000, 99999999)
|
||||||
game = PlayGame(
|
game = PlayGame(
|
||||||
quiz_id=quiz_id,
|
quiz_id=quiz_id,
|
||||||
|
|||||||
Reference in New Issue
Block a user