Explorar o código

change acl in user mutate

ilya_shyian %!s(int64=2) %!d(string=hai) anos
pai
achega
55f0f76c3c
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      store_back/apps/authAPI/schema.py

+ 1 - 1
store_back/apps/authAPI/schema.py

@@ -212,7 +212,7 @@ class UserUpsert(graphene.Mutation):
                 raise Exception("Authentication credentials were not provided")
             
             new_user.is_active = "active" in acl
-            new_user.is_admin = "admin" in acl
+            new_user.is_superuser = "admin" in acl
 
         new_user.save()