mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 05:12:45 +00:00
* win_security_policy: allow removing values (resolves #40869) * Removing warning * Adding test for remove policy setting * Fixing string comparison
This commit is contained in:
committed by
Jordan Borean
parent
1401fa74cc
commit
f2bd6b6bfd
@@ -194,6 +194,8 @@ if ($will_change -eq $true) {
|
||||
if ($new_value -cne $value) {
|
||||
Fail-Json $result "Failed to change the value for key '$key' in section '$section', the value is still $new_value"
|
||||
}
|
||||
} elseif ([string]$value -eq "") {
|
||||
# Value was empty, so OK if no longer in the result
|
||||
} else {
|
||||
Fail-Json $result "The key '$key' in section '$section' is not a valid key, cannot set this value"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user