File tree Expand file tree Collapse file tree 1 file changed +9
-5
lines changed
Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -6,11 +6,15 @@ function New-CIPPTemplateRun {
66 )
77 $Table = Get-CippTable - tablename ' templates'
88 $ExistingTemplates = (Get-CIPPAzDataTableEntity @Table ) | ForEach-Object {
9- $data = $_.JSON | ConvertFrom-Json - ErrorAction SilentlyContinue - Depth 100
10- $data | Add-Member - NotePropertyName ' GUID' - NotePropertyValue $_.RowKey - Force
11- $data | Add-Member - NotePropertyName ' PartitionKey' - NotePropertyValue $_.PartitionKey - Force
12- $data | Add-Member - NotePropertyName ' SHA' - NotePropertyValue $_.SHA - Force
13- $data
9+ try {
10+ $data = $_.JSON | ConvertFrom-Json - ErrorAction SilentlyContinue - Depth 100
11+ $data | Add-Member - NotePropertyName ' GUID' - NotePropertyValue $_.RowKey - Force - ErrorAction Stop
12+ $data | Add-Member - NotePropertyName ' PartitionKey' - NotePropertyValue $_.PartitionKey - Force - ErrorAction Stop
13+ $data | Add-Member - NotePropertyName ' SHA' - NotePropertyValue $_.SHA - Force - ErrorAction Stop
14+ $data
15+ } catch {
16+ return
17+ }
1418 } | Sort-Object - Property displayName
1519
1620 function Get-SanitizedFilename {
You can’t perform that action at this time.
0 commit comments