Add ImplementationDetail member only when the member does not already exist

This commit is contained in:
Andrew
2023-02-23 19:59:36 -08:00
parent 68cfed18c9
commit a9182cf60e
@@ -4140,7 +4140,8 @@ function GetResourceFromKeyword
$schemaToProcess = $classesFromSchema | ForEach-Object -Process {
if(($_.CimSystemProperties.ClassName -ieq $keyword.ResourceName) -and ($_.CimSuperClassName -ieq 'OMI_BaseResource'))
{
if ([ExperimentalFeature]::IsEnabled("PSDesiredStateConfiguration.InvokeDscResource"))
$member = Get-Member -InputObject $_ -MemberType NoteProperty -Name 'ImplementationDetail'
if ($null -eq $member)
{
$_ | Add-Member -MemberType NoteProperty -Name 'ImplementationDetail' -Value $implementationDetail -PassThru
}