Skip to content

Commit

Permalink
Initial
Browse files Browse the repository at this point in the history
  • Loading branch information
NikCharlebois committed Jul 20, 2022
1 parent fa86e5b commit 911a530
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -499,9 +499,10 @@ function Export-TargetResource
try
{
$policyTemplateID='d02f2162-fcac-48db-9b7b-b0a3f160d2c2_1'
[array]$policies = Get-MgDeviceManagementConfigurationPolicy `
[array]$allPolicies = Get-MgDeviceManagementConfigurationPolicy `
-ErrorAction Stop `
-TemplateId $policyTemplateID
-All:$true
$policies = $allPolicies | Where-Object -FilterScript {$_.TemplateReference.TemplateId -eq $policyTemplateId}

if ($policies.Length -eq 0)
{
Expand Down

0 comments on commit 911a530

Please sign in to comment.