mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-25 03:41:25 -07:00
Fix logic surrounding copy and remote_src, remote_src is preferred, make copy action plugin only. Fixes #23591 (#24732)
This commit is contained in:
parent
f5fd32eae6
commit
4ac135c1b5
2 changed files with 4 additions and 7 deletions
|
@ -53,7 +53,7 @@ class ActionModule(ActionBase):
|
|||
return result
|
||||
# We will take the information from copy and store it in
|
||||
# the remote_src var to use later in this file.
|
||||
remote_src = not boolean(self._task.args.get('copy'))
|
||||
self._task.args['remote_src'] = remote_src = not boolean(self._task.args.pop('copy'))
|
||||
|
||||
if source is None or dest is None:
|
||||
result['failed'] = True
|
||||
|
@ -128,7 +128,7 @@ class ActionModule(ActionBase):
|
|||
)
|
||||
|
||||
# remove action plugin only key
|
||||
for key in ('remote_src', 'decrypt'):
|
||||
for key in ('decrypt',):
|
||||
if key in new_module_args:
|
||||
del new_module_args[key]
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue