getPlatform: avoid returning bad strings