You are here

function sbp_nodes_comment in Search by Page 6

Implementation of hook_comment().

When a comment is added, edited, or deleted, set its node for reindexing at the next cron run.

File

./sbp_nodes.module, line 262
Module file for Search by Page Nodes, a sub-module for Search by Page.

Code

function sbp_nodes_comment($a1, $op) {
  switch ($op) {
    case 'insert':
    case 'update':
    case 'delete':
    case 'publish':
    case 'unpublish':
      search_by_page_force_reindex('sbp_nodes', is_array($a1) ? $a1['nid'] : $a1->nid);
      break;
  }
}