Fixed validation on nullable type