Make sure dwim'd relative path ends in a "/" if the original does

Fixes #7296
pull/7527/head
James Cammarata 11 years ago
parent b01da1b780
commit 4d0ce5bd41

@ -32,6 +32,7 @@ class ActionModule(object):
if 'vars' in self.inject:
if '_original_file' in self.inject['vars']:
# roles
original_path = path
path = utils.path_dwim_relative(self.inject['_original_file'], 'files', path, self.runner.basedir)
if original_path and original_path[-1] == '/' and path[-1] != '/':
# make sure the dwim'd path ends in a trailing "/"

Loading…
Cancel
Save