Field Type: User Reference
Field Widget: Check boxes/radio buttons

When using editable fields with a user reference field I get the following error when attempting to save selections: "FieldLabel: this user can't be referenced." This is coming from the user_reference.module:

 // Prevent performance hog if there are no ids to check.
  if ($ids) {
    $options = array(
      'ids' => $ids,
    );
    $refs = user_reference_potential_references($field, $options);
    foreach ($items as $delta => $item) {
      if (is_array($item)) {
        if (!empty($item['uid']) && !isset($refs[$item['uid']])) {
          $errors[$field['field_name']][$langcode][$delta][] = array(
            'error' => 'invalid_uid',
            'message' => t("%name: this user can't be referenced.",
              array('%name' => $instance['label'])),
          );
        }
      }
    }
  }
} 

But this only happens when using the editablefields functionality. If I go into the node edit page and make the edits then it works just fine. Any thoughts?

Comments

Kirschbaum’s picture

An addition note: As I mentioned when I select the users from the regular node edit page things work fine. They even show up as being checked when I go back to the detail page. However, when I try to deselect the user references using the editable fields feature, I get the following error message:

An AJAX HTTP error occurred.
HTTP Result Code: 500
Debugging information follows.
Path: /system/ajax
StatusText: Service unavailable (with message)
ResponseText: Recoverable fatal error: Argument 1 passed to drupal_array_get_nested_value() must be of the type array, boolean given, called in /Applications/MAMP/htdocs/support.loc/sites/all/modules/editablefields/editablefields.module on line 315 and defined in drupal_array_get_nested_value() (line 6578 of /Applications/MAMP/htdocs/support.loc/includes/common.inc).