Better platform detection