item_type === 'node'; } /** * Alter items before indexing. * * Items which are removed from the array won't be indexed, but will be marked * as clean for future indexing. * * @param array $items * An array of items to be altered, keyed by item IDs. */ public function alterItems(array &$items) { foreach ($items as $nid => &$item) { if (empty($item->status)) { unset($items[$nid]); } } } }