Update Update-WinGet.ps1
Workaround for a weird bug encountered in pwsh 7.
Proposed Changes
For some reason our usual (& winget) did not work as expectedWith legacy approach there was no such issue.
Related Issues
(#575)
Weird that we have to do that to get it to work...
I am not a big fan of over-complicating code when not necessary as well, If issue reported in https://github.com/Romanitho/Winget-AutoUpdate/issues/575 resurfaces, then we have an alternative on standby.
Call me cray, but it think that this issue (https://github.com/Romanitho/Winget-AutoUpdate/issues/594) may be affected by the same problem.
@Romanitho: I advise adding the PoSh version field to issue template.
yes we can add this field. But it's weird that #594 is affected by this.