fix: auto enable new players

This commit is contained in:
julius 2025-03-24 22:41:03 +01:00
parent 19ae4a18ca
commit 90adb4fc9c
Signed by: julius
GPG Key ID: C80A63E6A5FD7092

View File

@ -56,6 +56,7 @@ def add_player(
display_name=r.display_name,
email=r.email if r.email else None,
number=r.number,
disabled=False,
teams=[team],
)
session.add(new_player)
@ -150,7 +151,7 @@ async def list_players(team_id: int):
select(P)
.join(PlayerTeamLink)
.join(Team)
.where(Team.id == team_id, P.disabled != True)
.where(Team.id == team_id, P.disabled == False)
).all()
if players:
return [