simplify validation on deserialization