Merge pull request #4480 from joemaller/absent_path_fix

ignore src when file module state=absent
This commit is contained in:
jctanner 2013-10-16 17:29:21 -07:00
commit 9543169cca

View file

@ -178,7 +178,7 @@ def main():
if src: if src:
src = os.path.expanduser(src) src = os.path.expanduser(src)
if src is not None and os.path.isdir(path) and state != "link": if src is not None and os.path.isdir(path) and state not in ["link", "absent"]:
params['path'] = path = os.path.join(path, os.path.basename(src)) params['path'] = path = os.path.join(path, os.path.basename(src))
file_args = module.load_file_common_arguments(params) file_args = module.load_file_common_arguments(params)