Fix ifs in platform checks