Skip to content

Commit 182fe09

Browse files
authored
Change Preset Type and Contains (#2789)
1 parent 02751c7 commit 182fe09

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

functions/public/Invoke-WPFImpex.ps1

+1-2
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,7 @@ function Invoke-WPFImpex {
5656
}
5757
}
5858
}
59-
60-
$flattenedJson = [string]$flattenedJson
59+
6160
Invoke-WPFPresets -preset $flattenedJson -imported $true
6261
}
6362
}

functions/public/Invoke-WPFPresets.ps1

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ function Invoke-WPFPresets {
1717

1818
param (
1919
[Parameter(position=0)]
20-
[string]$preset = "",
20+
[Array]$preset = "",
2121

2222
[Parameter(position=1)]
2323
[bool]$imported = $false,
@@ -51,7 +51,7 @@ function Invoke-WPFPresets {
5151
}
5252

5353
# Check if the checkbox name exists in the flattened JSON hashtable
54-
if ($CheckBoxesToCheck.Contains($checkboxName)) {
54+
if ($CheckBoxesToCheck -contains $checkboxName) {
5555
# If it exists, set IsChecked to true
5656
$sync.$checkboxName.IsChecked = $true
5757
Write-Debug "$checkboxName is checked"

0 commit comments

Comments
 (0)