From 5e9cd8a7e7d399073899a7a1a63cf259612509f5 Mon Sep 17 00:00:00 2001 From: Raphire <9938813+Raphire@users.noreply.github.com> Date: Tue, 26 Nov 2024 22:52:45 +0100 Subject: [PATCH] Now prompts for forceful MS Edge uninstall if Winget fails, regardless of exit code --- Win11Debloat.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Win11Debloat.ps1 b/Win11Debloat.ps1 index d90bc0f..13001a3 100644 --- a/Win11Debloat.ps1 +++ b/Win11Debloat.ps1 @@ -353,7 +353,7 @@ function RemoveApps { # Uninstall app via winget Strip-Progress -ScriptBlock { winget uninstall --accept-source-agreements --disable-interactivity --id $app } | Tee-Object -Variable wingetOutput - If (($app -eq "Microsoft.Edge") -and (Select-String -InputObject $wingetOutput -Pattern "93")) { + If (($app -eq "Microsoft.Edge") -and (Select-String -InputObject $wingetOutput -Pattern "Uninstall failed with exit code")) { Write-Host "Unable to uninstall Microsoft Edge via Winget" -ForegroundColor Red Write-Output ""