Skip to content

Commit a099e6b

Browse files
force templates to be an array
1 parent 56cc68e commit a099e6b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Endpoint/MEM/Invoke-ListIntuneTemplates.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ function Invoke-ListIntuneTemplates {
5656
value = $package
5757
type = 'tag'
5858
templateCount = ($RawTemplates | Where-Object { $_.Package -eq $package }).Count
59-
templates = ($RawTemplates | Where-Object { $_.Package -eq $package } | ForEach-Object {
59+
templates = @($RawTemplates | Where-Object { $_.Package -eq $package } | ForEach-Object {
6060
try {
6161
$JSONData = $_.JSON | ConvertFrom-Json -Depth 100 -ErrorAction SilentlyContinue
6262
$data = $JSONData.RAWJson | ConvertFrom-Json -Depth 100 -ErrorAction SilentlyContinue

0 commit comments

Comments
 (0)