diff --git a/bucket/mp3tag_fixed.json b/bucket/mp3tag_fixed.json index b410307c6..4a94c7359 100644 --- a/bucket/mp3tag_fixed.json +++ b/bucket/mp3tag_fixed.json @@ -55,10 +55,12 @@ "Copy-Item \"$scriptsdir\\uninstall-mp3tag-context.cmd\" \"$dir\\uninstall-mp3tag-context.cmd\"" ], "pre_uninstall": [ - "reg delete 'HKCU\\SOFTWARE\\Classes\\*\\shell\\&Mp3tag' /f", - "reg delete 'HKCU\\SOFTWARE\\Classes\\*\\shell\\Mp3tag' /f", - "reg delete 'HKCU\\SOFTWARE\\Classes\\Directory\\shell\\&Mp3tag' /f", - "reg delete 'HKCU\\SOFTWARE\\Classes\\Directory\\shell\\Mp3tag' /f" + "if ($cmd -eq 'uninstall') {", + " reg delete 'HKCU\\SOFTWARE\\Classes\\*\\shell\\&Mp3tag' /f", + " reg delete 'HKCU\\SOFTWARE\\Classes\\*\\shell\\Mp3tag' /f", + " reg delete 'HKCU\\SOFTWARE\\Classes\\Directory\\shell\\&Mp3tag' /f", + " reg delete 'HKCU\\SOFTWARE\\Classes\\Directory\\shell\\Mp3tag' /f", + "}" ], "checkver": { "url": "https://www.mp3tag.de/en/download.html",