Fix ipavault vault_type under Python 2.7.

When running module ipavault with Python 2.7, due to differences in
the handling of unicode string than in Python 3, the vault_type type
was different than the required.

This patch changes the default value to force a unicode string in
the supported versions of Python, fixing the module when Python 2
is used.
This commit is contained in:
Rafael Guterres Jeffman
2020-08-22 21:13:04 -03:00
parent c2f68a3401
commit 8b06e31e26

View File

@@ -756,7 +756,7 @@ def main():
res_vault_type = res_find.get('ipavaulttype')[0]
args['ipavaulttype'] = vault_type = res_vault_type
else:
args['ipavaulttype'] = vault_type = "symmetric"
args['ipavaulttype'] = vault_type = u"symmetric"
# Create command
if state == "present":