mirror of
https://github.com/ansible/awx.git
synced 2026-01-17 04:31:21 -03:30
Incorrect object reference in Custom Inventory Script read acl for non-super-users
This commit is contained in:
parent
1c1aa1f807
commit
96433b07d4
@ -1471,7 +1471,7 @@ class CustomInventoryScriptAccess(BaseAccess):
|
||||
def can_read(self, obj):
|
||||
if self.user.is_superuser:
|
||||
return True
|
||||
if not self.active:
|
||||
if not obj.active:
|
||||
return False
|
||||
return bool(obj.organization in self.user.organizations.all() or obj.organization in self.user.admin_of_organizations.all())
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user