I think there’s a slight problem with the WMI filter on that post.
In fact it’s listed in the comments:
select * from Win32_OperatingSystem where (Version like “6.%” OR Version like “10.%”) and ProductType = “1”
or you can do it like this:
select * from Win32_OperatingSystem where (Version >= “6.1%” or Version like “10.%”) and ProductType = “1”