API page: http://api.drupal.org/api/drupal/modules--field_ui--field_ui.admin.inc/f...
Describe the problem you have found:
It is not documentation problem is a code problem in field_ui_field_edit_form_validate function
instead of line "$instance = $form_state['values']['instance']; "
should be line "$instance = $form['instance'];"
because hook_field_validate($obj_type, $object, $field, $instance, $langcode, &$items, &$errors)
called by field_ui_field_edit_form_validate the $instance parameter delivered by field_ui_field_edit_form_validate to hook_field_validate should include the same data that $instance parameter of all other field hooks (for example hook_field_settings_form($field, $instance, $has_data)) includes.
Comments
Comment #1
Anonymous (not verified) CreditAttribution: Anonymous commentedBut if the user is changing the instance settings, as field_ui_field_edit_form does, don't you want to validate the values that the user has entered into the form for the instance settings?
Comment #1.0
Anonymous (not verified) CreditAttribution: Anonymous commentedi changed the explanation