From c4d3bf3207641d0c75868ddc1e42b18303df355e Mon Sep 17 00:00:00 2001 From: Tim Rupp Date: Sat, 11 Feb 2017 15:15:04 -0800 Subject: [PATCH] Adds path type and remove expanduser Related to #12263, this patch removes the usage of expanduser in favor of the path 'type' for the module options of src and dest --- lib/ansible/modules/files/assemble.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/ansible/modules/files/assemble.py b/lib/ansible/modules/files/assemble.py index b6f1d0329f..0bf494ff9d 100644 --- a/lib/ansible/modules/files/assemble.py +++ b/lib/ansible/modules/files/assemble.py @@ -188,9 +188,9 @@ def main(): module = AnsibleModule( # not checking because of daisy chain to file module argument_spec = dict( - src = dict(required=True), + src = dict(required=True, type='path'), delimiter = dict(required=False), - dest = dict(required=True), + dest = dict(required=True, type='path'), backup=dict(default=False, type='bool'), remote_src=dict(default=False, type='bool'), regexp = dict(required=False), @@ -203,8 +203,8 @@ def main(): changed = False path_hash = None dest_hash = None - src = os.path.expanduser(module.params['src']) - dest = os.path.expanduser(module.params['dest']) + src = module.params['src'] + dest = module.params['dest'] backup = module.params['backup'] delimiter = module.params['delimiter'] regexp = module.params['regexp']