azureautomation / runbooks

Sample Automation runbooks
MIT License
150 stars 128 forks source link

Error in Get-AutomationVariable for PowerShell 7.2 #99

Open LuckyLeo2008 opened 1 year ago

LuckyLeo2008 commented 1 year ago

I noticed that Get-AutomationVariable in PowerShell 7.1 returns a normal string for a string variable:

But in PowerShell 7.2 the returned string contains quotation marks as part of the variable itself:

I'm not sure if this is due to the implementation of Get-AutomationVariable or something in the new PowerShell version, but it seems like you should not have to strip quotation marks from a string variable prior to using it.