From e50f20eb69644d66710bbb40c0942d62dcbd04db Mon Sep 17 00:00:00 2001 From: Akita Noek Date: Mon, 2 May 2016 15:56:05 -0400 Subject: [PATCH] Check can_update for ProjectAccess.can_start for superusers too can_update is a special model getter that checks to see if the project is in a valid state it looks like - so it's important to check this for superusers too. The can_change check does the implicit is_superuser check for us, so we don't need another expclit check here, just can_start protection. --- awx/main/access.py | 1 - 1 file changed, 1 deletion(-) diff --git a/awx/main/access.py b/awx/main/access.py index 3b68d9e781..ffd5da98c9 100644 --- a/awx/main/access.py +++ b/awx/main/access.py @@ -679,7 +679,6 @@ class ProjectAccess(BaseAccess): def can_delete(self, obj): return self.can_change(obj, None) - @check_superuser def can_start(self, obj): return self.can_change(obj, {}) and obj.can_update