mirror of https://github.com/ansible/ansible.git
fix handling of nics argument
The existing code was receiving a list of strings and erroneously assuming it was being given a list of dictionaries, leading it to fail with: AttributeError: 'str' object has no attribute 'get' This commit corrects the list handling code to check the type of each item and handle it appropriately. Also, based on bcoca's comment in #2253, thie code removes the special case for a string-only argument. By transforming string arguments into dicts and then handling them like any other dict argument, this also permits arguments of the form: nics: net-name=mynet Or: nics: port-name=mynet Previous versions of this code only supported `net-id` and `port-id` in string specifications.pull/18777/head
parent
db59af564e
commit
413a9d0c62
Loading…
Reference in New Issue