From d76ae5cd1dd000f255b95b9930504a190a6ea5fd Mon Sep 17 00:00:00 2001 From: Przemyslaw Klys Date: Sun, 2 Aug 2020 00:31:52 +0200 Subject: [PATCH] Lithnet update, but most likely to remove --- Private/ConvertTo-XMLLithnetFilter.ps1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Private/ConvertTo-XMLLithnetFilter.ps1 b/Private/ConvertTo-XMLLithnetFilter.ps1 index 7d64d2b..f09671f 100644 --- a/Private/ConvertTo-XMLLithnetFilter.ps1 +++ b/Private/ConvertTo-XMLLithnetFilter.ps1 @@ -73,14 +73,14 @@ function ConvertTo-XMLLithnetFilter { $UsedNames = [System.Collections.Generic.List[string]]::new() if ($GPO.DataSet.Category -like 'Lithnet/Password Protection for Active Directory*') { foreach ($Policy in $GPO.DataSet) { - $Name = Format-ToTitleCase -Text $Policy.Name -RemoveWhiteSpace -RemoveChars ',', '-', "'", '\(', '\)', ':' + $Name = Format-ToTitleCase -Text $Policy.Name -RemoveWhiteSpace -RemoveChar ',', '-', "'", '\(', '\)', ':' $CreateGPO[$Name] = $Policy.State foreach ($Setting in @('DropDownList', 'Numeric', 'EditText', 'Text', 'CheckBox')) { if ($Policy.$Setting) { foreach ($Value in $Policy.$Setting) { if ($Value.Name) { - $SubName = Format-ToTitleCase -Text $Value.Name -RemoveWhiteSpace -RemoveChars ',', '-', "'", '\(', '\)', ':' + $SubName = Format-ToTitleCase -Text $Value.Name -RemoveWhiteSpace -RemoveChar ',', '-', "'", '\(', '\)', ':' $SubName = -join ($Name, $SubName) if ($SubName -notin $UsedNames) { $UsedNames.Add($SubName)