-
-
Notifications
You must be signed in to change notification settings - Fork 117
Closed
Labels
Description
Describe the bug
When passing a hash table, whose one of the values contains an array of hash tables, to Convert-HashtableToCode, the output is not as expected.
To Reproduce
C:\> $department = @{DepartmentName="IT"; Managers = @(@{Name="John"; Age=33}, @{Name="David"; Age = 31})}
C:\> Convert-HashtableToCode $department
@{
Managers = 'System.Collections.Hashtable','System.Collections.Hashtable'
DepartmentName = 'IT'
}
Expected behavior
The output should be:
@{
Managers = @(@{Name="John"; Age=33}, @{Name="David"; Age = 31})
DepartmentName = 'IT'
}
Desktop (please complete the following information):
- Operating System Version: Windows 10
- Module Version: 2.29.0
- PowerShell Version: 5.1.19041.1
- Powershell Edition: Desktop