mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Restore force in copy since arguments are no longer clobbered
Fixes #2388.
This commit is contained in:
parent
27978ed9c1
commit
fc227fbd37
1 changed files with 2 additions and 2 deletions
|
@ -105,8 +105,8 @@ def main():
|
|||
md5sum_dest = None
|
||||
|
||||
if os.path.exists(dest):
|
||||
# if not force:
|
||||
# module.exit_json(msg="file already exists and force is set (%s)" % force, src=src, dest=dest, changed=False)
|
||||
if not force:
|
||||
module.exit_json(msg="file already exists", src=src, dest=dest, changed=False)
|
||||
if (os.path.isdir(dest)):
|
||||
basename = os.path.basename(src)
|
||||
dest = os.path.join(dest, basename)
|
||||
|
|
Loading…
Reference in a new issue