function tripal_field_validate

3.x tripal.fields.inc tripal_field_validate($entity_type, $entity, $field, $instance, $langcode, $items, &$errors)

Implements hook_field_validate()

File

tripal/includes/tripal.fields.inc, line 862

Code

function tripal_field_validate($entity_type, $entity, $field, $instance, 
$langcode, $items, &$errors) {

  $field_type = $field['type'];
  if (tripal_load_include_field_class($field_type)) {
    $tfield = new $field_type($field, $instance);
    $tfield->validate($entity_type, $entity, $langcode, $items, $errors);
  }
}