Skip to content

Commit 8fa1014

Browse files
committed
Added is_staff flag to initial superuser, refs #389.
1 parent 9de8900 commit 8fa1014

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

api/views.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ def pre_save(self, obj):
133133
obj.set_password(obj.password)
134134
# Make this first signup an admin / superuser
135135
if not User.objects.filter(is_superuser=True).exists():
136-
obj.is_superuser = True
136+
obj.is_superuser = obj.is_staff = True
137137

138138

139139
class UserCancellationView(viewsets.GenericViewSet,

0 commit comments

Comments
 (0)