Changed method to determine platform