diff --git a/automatic/graphviz/tools/chocolateyUninstall.ps1 b/automatic/graphviz/tools/chocolateyUninstall.ps1 index e1ef0c08469..d9cb905b86a 100644 --- a/automatic/graphviz/tools/chocolateyUninstall.ps1 +++ b/automatic/graphviz/tools/chocolateyUninstall.ps1 @@ -14,7 +14,7 @@ if ($key.Count -eq 1) { file = "$($_.UninstallString.Replace(' /x86=0', ''))" #"C:\Program Files\OpenSSH\uninstall.exe" /x86=0 } - $installLocation = (Get-Item $key.UninstallString).DirectoryName + $installLocation = $(Split-Path $_.UninstallString.trim('"') ) Write-Debug "$packageName installed in: $installLocation" if (!$installLocation) {