1
0
mirror of https://github.com/ansible/awx.git synced 2024-10-31 15:21:13 +03:00

Return passwords_needed_to_start when not provided via POST to start job.

This commit is contained in:
Chris Church 2013-05-21 11:21:22 -04:00
parent 14b09dcc1a
commit 06239b4c04

View File

@ -973,7 +973,8 @@ class JobStart(generics.RetrieveAPIView):
if obj.can_start:
result = obj.start(**request.DATA)
if not result:
return Response(status=400)
data = dict(passwords_needed_to_start=obj.get_passwords_needed_to_start())
return Response(data, status=400)
else:
return Response(status=202)
else: