Skip to content

Commit

Permalink
Fix upstream issue dsccommunity#27
Browse files Browse the repository at this point in the history
  • Loading branch information
solbirn committed May 17, 2018
1 parent 831fdde commit bd803f6
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,7 @@ function Set-TargetResource
} # foreach

# Get the existing folders of this DFS Rep Group
$existingFolders = (Get-DfsReplicatedFolder @replicationGroupParameters -ErrorAction Stop).FolderName
$existingFolders = @((Get-DfsReplicatedFolder @replicationGroupParameters -ErrorAction Stop).FolderName) -replace "^$", "null"

# Add any missing folders
foreach ($folder in $Folders)
Expand Down Expand Up @@ -625,7 +625,7 @@ function Test-TargetResource
$replicationGroupParameters.Remove('ComputerName')

# Compare the Members
$existingMembers = @((Get-DfsrMember @replicationGroupParameters -ErrorAction Stop).DnsName)
$existingMembers = @((Get-DfsrMember @replicationGroupParameters -ErrorAction Stop).DnsName) -replace "^$", "null"
if ((Compare-Object `
-ReferenceObject $fqdnMembers `
-DifferenceObject $existingMembers).Count -ne 0)
Expand All @@ -641,7 +641,7 @@ function Test-TargetResource
} # if

# Compare the Folders
$existingFolders = @((Get-DfsReplicatedFolder @replicationGroupParameters -ErrorAction Stop).FolderName)
$existingFolders = @((Get-DfsReplicatedFolder @replicationGroupParameters -ErrorAction Stop).FolderName) -replace "^$", "null"

if ((Compare-Object `
-ReferenceObject $Folders `
Expand Down

0 comments on commit bd803f6

Please sign in to comment.