Private
Public Access
1
0

improved privileges

This commit is contained in:
Sander Roosendaal
2019-08-29 07:47:02 +02:00
parent b5935b9a19
commit 3357a06d4a
2 changed files with 11 additions and 14 deletions

View File

@@ -135,8 +135,8 @@ def add_member(id,rower):
t= Team.objects.get(id=id)
try:
rower.team.add(t)
except ValidationError:
return(0,"Couldn't add member")
except ValidationError as e:
return(0,"Couldn't add member: "+str(e.message))
# code to add all workouts
ws = Workout.objects.filter(user=rower)