You are here

function taxonomy_entity_index_entity_delete in Taxonomy Entity Index 7

Same name and namespace in other branches
  1. 8 taxonomy_entity_index.module \taxonomy_entity_index_entity_delete()

Implements hook_entity_delete().

File

./taxonomy_entity_index.module, line 33

Code

function taxonomy_entity_index_entity_delete($entity, $entity_type) {
  list($entity_id) = entity_extract_ids($entity_type, $entity);
  db_delete('taxonomy_entity_index')
    ->condition('entity_type', $entity_type)
    ->condition('entity_id', $entity_id)
    ->execute();
}