code: function checkValueSubmitted(submittedField, fieldDefinition, visible, cb) {
          if (!fieldDefinition.required) {
            return cb(undefined, null);
          }
  
          var valueSubmitted = submittedField && submittedField.fieldValues && (submittedField.fieldValues.length > 0);
          //No value submitted is only an error if the field is visible.
  
          //If the field value has been marked as not required, then don't fail a no-value submission
          var valueRequired = requiredFieldMap[fieldDefinition._id] && requiredFieldMap[fieldDefinition._id].valueRequired;
  
          if (!valueSubmitted && visible && valueRequired) {
            return cb(undefined, "No value submitted for field " + fieldDefinition.name);
          }
          return cb(undefined, null);
  
        }
docs: just functions below this