check if field is mandatory