Change credential to return 'ssh_password' instead of 'password' when value is set to 'ASK'.

This commit is contained in:
Chris Church
2015-04-08 15:32:45 -04:00
parent 53bc065d32
commit 9500e9b63e
3 changed files with 8 additions and 16 deletions

View File

@@ -113,14 +113,10 @@ class AdHocCommand(UnifiedJob):
@property
def passwords_needed_to_start(self):
'''Return list of password field names needed to start the job.'''
needed = []
if self.credential:
for pw in self.credential.passwords_needed:
if pw == 'password':
needed.append('ssh_password')
else:
needed.append(pw)
return needed
return self.credential.passwords_needed
else:
return []
@classmethod
def _get_parent_field_name(cls):