From 077498836569dd45ec9bbb5c95d4604163eef1cd Mon Sep 17 00:00:00 2001 From: orin Date: Wed, 14 Jan 2026 13:51:59 +0100 Subject: [PATCH] Fix Windows CPC OS names. Doubled build number in the name is Microsoft's fault and I can't be bothered to make a hackfix that. --- fetchupd.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fetchupd.php b/fetchupd.php index 359abcf..127ea72 100644 --- a/fetchupd.php +++ b/fetchupd.php @@ -370,7 +370,7 @@ function parseFetchUpdate($updateInfo, $out, $arch, $ring, $flight, $build, $sku $updateTitle = str_replace('Windows 11', 'Windows Server', $updateTitle); } - if(preg_match('/Windows 1\d|Server|Azure Stack HCI/i', $updateTitle) !== 1) { + if(preg_match('/Windows 1\d|Server|Azure Stack HCI|Windows CPC OS/i', $updateTitle) !== 1) { $osName = $foundType != 'server' ? 'Windows 11' : 'Microsoft server operating system'; $updateTitle = str_replace('Update', "Update for $osName", $updateTitle); } @@ -384,7 +384,7 @@ function parseFetchUpdate($updateInfo, $out, $arch, $ring, $flight, $build, $sku if($foundType == 'hololens' || $foundType == 'wcosdevice0') $updateTitle = $updateTitle.' - '.$type; - if(!preg_match("/$foundBuild/i", $updateTitle)) + if(!str_contains($updateTitle, $foundBuild)) $updateTitle = $updateTitle.' ('.$foundBuild.')'; preg_match('/UpdateID=".*?"/', $updateInfo, $updateId);