parent
ee478c4885
commit
78de05e58d
|
@ -32,8 +32,9 @@ $state = Get-AnsibleParam -obj $params -name "state" -default "present" -validat
|
||||||
# Attributes parameter - Pipe separated list of attributes where
|
# Attributes parameter - Pipe separated list of attributes where
|
||||||
# keys and values are separated by comma (paramA:valyeA|paramB:valueB)
|
# keys and values are separated by comma (paramA:valyeA|paramB:valueB)
|
||||||
$attributes = @{};
|
$attributes = @{};
|
||||||
If (Get-Member -InputObject $params -Name attributes) {
|
$attrs = Get-AnsibleParam -obj $params -name "attributes" -type "string" -failifempty $false
|
||||||
$params.attributes -split '\|' | foreach {
|
If ($attrs) {
|
||||||
|
$attrs -split '\|' | foreach {
|
||||||
$key, $value = $_ -split "\:"
|
$key, $value = $_ -split "\:"
|
||||||
$attributes.Add($key, $value)
|
$attributes.Add($key, $value)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue