Fix new organizer role

This commit is contained in:
Yohann D'ANELLO 2020-05-05 18:17:48 +02:00
parent 7bd2e1626f
commit 28abf730a2
1 changed files with 1 additions and 2 deletions

View File

@ -56,9 +56,8 @@ class OrganizerForm(forms.ModelForm):
def save(self, commit=True):
user = self.instance
print(user)
print(user.pk)
user.role = '0admin' if user.is_superuser else '1organizer'
user.save()
super().save(commit)