Skip to content

Commit d3d1c19

Browse files
Free access to flappy bird data (#709)
There is an unprotected endpoint that gives access to data from every user that played --------- Co-authored-by: Marc-Andrieu <[email protected]>
1 parent 59aebc7 commit d3d1c19

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

app/modules/flappybird/endpoints_flappybird.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,10 @@
2626
response_model=list[schemas_flappybird.FlappyBirdScoreInDB],
2727
status_code=200,
2828
)
29-
async def get_flappybird_score(db: AsyncSession = Depends(get_db)):
29+
async def get_flappybird_score(
30+
db: AsyncSession = Depends(get_db),
31+
user: models_users.CoreUser = Depends(is_user_a_member),
32+
):
3033
"""Return the leaderboard"""
3134
return await cruds_flappybird.get_flappybird_score_leaderboard(db=db)
3235

0 commit comments

Comments
 (0)