Skip to content

Commit bc98e7f

Browse files
committed
Refactor Get() method to output sorted environment variables in DebugDscEngine class
1 parent 32ed0ae commit bc98e7f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

source/Classes/020.DebugDscEngine.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ class DebugDscEngine : ResourceBase
9191
[DebugDscEngine] Get()
9292
{
9393
# Output all environment variables to verify the environment
94-
#Write-Verbose -Message "`nEnvironment Variables from inside DSC resource:`n$(Get-ChildItem -Path Env: | Out-String)" -Verbose
94+
#Write-Verbose -Message "`nEnvironment Variables from inside DSC resource:`n$([System.Environment]::GetEnvironmentVariables().GetEnumerator() | Sort-Object Key | ForEach-Object { "$($_.Key) = $($_.Value)" } | Out-String)" -Verbose
9595

9696
# Call the base method to return the properties.
9797
return ([ResourceBase] $this).Get()

0 commit comments

Comments
 (0)