Ignore non-functioning update

This commit is contained in:
Manuel Thalmann 2023-07-16 01:22:43 +02:00
parent 055f1706f9
commit df0ba4da11

View file

@ -18,7 +18,9 @@ function Update-WindowsInstallation([Context] $context)
$context.Reboot();
exit;
}
elseif ((Get-WindowsUpdate -IgnoreReboot).Count -gt 0)
elseif (
((Get-WindowsUpdate -IgnoreReboot).Count -gt 0) -and
((Get-WindowsUpdate -IgnoreReboot).KB -ne "KB2267602"))
{
Write-Information "More updates are available. Restarting upgrade routine.";
$null = Update-WindowsInstallation $context;