mirror of
https://github.com/ansible/awx.git
synced 2026-04-06 18:49:21 -02:30
Check dynamic_input fields also with has_inputs() - Fixes,
using credential plugins in Container Registry credential, with execution environments Signed-off-by: quasd <qquasd@gmail.com>
This commit is contained in:
@@ -299,10 +299,7 @@ class Credential(PasswordFieldsModel, CommonModelNameNotUnique, ResourceMixin):
|
|||||||
|
|
||||||
def has_inputs(self, field_names=()):
|
def has_inputs(self, field_names=()):
|
||||||
for name in field_names:
|
for name in field_names:
|
||||||
if name in self.inputs:
|
if not self.has_input(name):
|
||||||
if self.inputs[name] in ('', None):
|
|
||||||
return False
|
|
||||||
else:
|
|
||||||
raise ValueError('{} is not an input field'.format(name))
|
raise ValueError('{} is not an input field'.format(name))
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user