ovirt_host_network: Fix type conversion

Signed-off-by: Ondra Machacek <omachace@redhat.com>
This commit is contained in:
Ondra Machacek 2018-10-25 14:21:23 +02:00 committed by Toshio Kuratomi
parent 6cfdd9f466
commit 0dc15986c2
2 changed files with 4 additions and 2 deletions

View file

@ -0,0 +1,2 @@
bugfixes:
- ovirt_host_network - Fix type conversion (https://github.com/ansible/ansible/pull/47617).

View file

@ -220,12 +220,12 @@ def get_bond_options(mode, usr_opts):
)
)
opts_dict = DEFAULT_MODE_OPTS.get(mode, {})
opts_dict = DEFAULT_MODE_OPTS.get(str(mode), {})
if usr_opts is not None:
opts_dict.update(**usr_opts)
options.extend(
[otypes.Option(name=opt, value=value)
[otypes.Option(name=opt, value=str(value))
for opt, value in six.iteritems(opts_dict)]
)
return options