Fix Windows 11 version reporting

This commit is contained in:
2Shirt 2022-09-04 18:10:54 -07:00
parent 5f69e23887
commit a97a71a24a
Signed by: 2Shirt
GPG key ID: 152FAC923B0E132C
2 changed files with 7 additions and 0 deletions

View file

@ -33,4 +33,9 @@ WINDOWS_BUILDS = {
'10.0.19042': '20H2',
'10.0.19043': '21H1',
'10.0.19044': '21H2',
'10.0.19045': '22H2',
# Windows 11
'10.0.22000': '21H2',
'10.0.22621': '22H2',
}

View file

@ -253,6 +253,8 @@ def get_os_name(as_list=False, check=True):
display_name = (
f'{reg_read_value("HKLM", key, "ProductName")} {ARCH}-bit {details}'
)
if build_version >= 22000:
display_name = display_name.replace('Windows 10', 'Windows 11')
# Check for support issues
if check: