Return only module_name for ad hoc command name.

This commit is contained in:
Chris Church 2015-04-27 21:35:40 -04:00
parent 8f83cc61b4
commit 2830095b07

View File

@ -1582,6 +1582,9 @@ class AdHocCommandSerializer(UnifiedJobSerializer):
ret['inventory'] = None
if 'credential' in ret and (not obj.credential or not obj.credential.active):
ret['credential'] = None
# For the UI, only module_name is returned for name, instead of the
# longer module name + module_args format.
ret['name'] = obj.module_name
return ret