diff --git a/CHANGELOG.md b/CHANGELOG.md index 9730326bb..baab612c9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -71,6 +71,7 @@ - Changes to xADOrganizationalUnit - Change the description of the property RestoreFromRecycleBin. - Code cleanup. + - Fix incorrect verbose message when this resource has Ensure set to Absent ([issue #276](https://github.com/PowerShell/xActiveDirectory/issues/276)). - Changes to xADUser - Change the description of the property RestoreFromRecycleBin. - Added ServicePrincipalNames property ([issue #153](https://github.com/PowerShell/xActiveDirectory/issues/153)). diff --git a/DSCResources/MSFT_xADOrganizationalUnit/MSFT_xADOrganizationalUnit.psm1 b/DSCResources/MSFT_xADOrganizationalUnit/MSFT_xADOrganizationalUnit.psm1 index 7dcba28a2..8aa742605 100644 --- a/DSCResources/MSFT_xADOrganizationalUnit/MSFT_xADOrganizationalUnit.psm1 +++ b/DSCResources/MSFT_xADOrganizationalUnit/MSFT_xADOrganizationalUnit.psm1 @@ -133,7 +133,7 @@ function Test-TargetResource else { $isCompliant = $true - Write-Verbose ($script:localizedData.OUInDesiredState -f $targetResource.Name) + Write-Verbose ($script:localizedData.OUDoesNotExistAndShouldNot -f $targetResource.Name) } } diff --git a/DSCResources/MSFT_xADOrganizationalUnit/en-US/MSFT_xADOrganizationalUnit.strings.psd1 b/DSCResources/MSFT_xADOrganizationalUnit/en-US/MSFT_xADOrganizationalUnit.strings.psd1 index 0c8e23c24..0727960ec 100644 --- a/DSCResources/MSFT_xADOrganizationalUnit/en-US/MSFT_xADOrganizationalUnit.strings.psd1 +++ b/DSCResources/MSFT_xADOrganizationalUnit/en-US/MSFT_xADOrganizationalUnit.strings.psd1 @@ -1,12 +1,13 @@ # culture="en-US" ConvertFrom-StringData @' - RetrievingOU = Retrieving OU '{0}'. - UpdatingOU = Updating OU '{0}'. - DeletingOU = Deleting OU '{0}'. - CreatingOU = Creating OU '{0}'. - RestoringOU = Attempting to restore the organizational unit object {0} from the recycle bin. - OUInDesiredState = OU '{0}' exists and is in the desired state. - OUNotInDesiredState = OU '{0}' exists but is not in the desired state. - OUExistsButShouldNot = OU '{0}' exists when it should not exist. - OUDoesNotExistButShould = OU '{0}' does not exist when it should exist. + RetrievingOU = Retrieving OU '{0}'. + UpdatingOU = Updating OU '{0}'. + DeletingOU = Deleting OU '{0}'. + CreatingOU = Creating OU '{0}'. + RestoringOU = Attempting to restore the organizational unit object {0} from the recycle bin. + OUInDesiredState = OU '{0}' exists and is in the desired state. + OUNotInDesiredState = OU '{0}' exists but is not in the desired state. + OUExistsButShouldNot = OU '{0}' exists when it should not exist. + OUDoesNotExistButShould = OU '{0}' does not exist when it should exist. + OUDoesNotExistAndShouldNot = OU '{0}' does not exist and is in the desired state. '@