mirror of
https://github.com/ansible/awx.git
synced 2026-01-12 02:19:58 -03:30
Deal with the (erroneous) case where a job is missing the inventory
by bailing out of check_org_host_limit early. Validation catches this situation later on.
This commit is contained in:
parent
cf75ea91a1
commit
4d06ae48d3
@ -336,6 +336,9 @@ class BaseAccess(object):
|
||||
return
|
||||
|
||||
inventory = get_object_from_data('inventory', Inventory, data)
|
||||
if inventory is None: # In this case a missing inventory error is launched
|
||||
return # further down the line, so just ignore it.
|
||||
|
||||
org = inventory.organization
|
||||
if org is None or org.max_hosts == 0:
|
||||
return
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user