I managed to get a series on notices once on the vocabulary term re-ordering page by creating a bunch of terms, then reordering, then resetting to alphabetical order without saving first. Haven't been able to reproduce since, but perhaps it's worth looking into.

Message:

Undefined index: tid:5:0 in modules/taxonomy/taxonomy.admin.inc on line 365.

(Repeated once for each term in the vocabulary.)

Relevant code:

  // If this form was already submitted once, it's probably hit a validation
  // error. Ensure the form is rebuilt in the same order as the user submitted.
  if (!empty($form_state['post'])) {
    $order = array_flip(array_keys($form_state['post'])); // Get the $_POST order.
    $current_page = array_merge($order, $current_page); // Update our form with the new order.
    foreach ($current_page as $key => $term) {
      // Verify this is a term for the current page and set at the current depth.
      if (is_array($form_state['post'][$key]) && is_numeric($form_state['post'][$key]['tid'])) { #365
        $current_page[$key]->depth = $form_state['post'][$key]['depth'];
      }
      else {
        unset($current_page[$key]);
      }
    }
  }

Comments

dpearcefl’s picture

Is this still happening in current D6?

Status: Active » Closed (outdated)

Automatically closed because Drupal 6 is no longer supported. If the issue verifiably applies to later versions, please reopen with details and update the version.