From 69de9d86bdd932b49d2f2fbc8238cd2cf66ef6cc Mon Sep 17 00:00:00 2001 From: Matt Davis Date: Wed, 28 Jun 2017 16:36:53 -0700 Subject: [PATCH] fix win_updates failure with dict-typed args (#26208) Switch to dicts in common code caused silent failures during arg translation, so default values and non-check-mode were always used. * fixes #23653 * fixes #24062 * fixes #22938 * fixes #25156 --- lib/ansible/modules/windows/win_updates.ps1 | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/lib/ansible/modules/windows/win_updates.ps1 b/lib/ansible/modules/windows/win_updates.ps1 index a74e68f366..af2a5d5792 100644 --- a/lib/ansible/modules/windows/win_updates.ps1 +++ b/lib/ansible/modules/windows/win_updates.ps1 @@ -405,9 +405,7 @@ $common_inject = { # source the common code into the current scope so we can call it . $common_inject -$parsed_args = Parse-Args $args $true -# grr, why use PSCustomObject for args instead of just native hashtable? -$parsed_args.psobject.properties | foreach -begin {$job_args=@{}} -process {$job_args."$($_.Name)" = $_.Value} -end {$job_args} +$job_args = Parse-Args $args $true # set the log_path for the global log function we injected earlier $log_path = $job_args['log_path']