You are here

function ds_search_invoke_node_search in Display Suite 7

Same name and namespace in other branches
  1. 7.2 modules/ds_search/ds_search.module \ds_search_invoke_node_search()

Invoke a given search hook on the node module.

Parameters

$hook: Hook to invoke.

2 calls to ds_search_invoke_node_search()
ds_search_search_status in modules/ds_search/ds_search.module
Implements hook_search_status().
ds_search_update_index in modules/ds_search/ds_search.module
Implements hook_node_update_index().

File

modules/ds_search/ds_search.module, line 225
Display Suite search.

Code

function ds_search_invoke_node_search($hook) {
  $enabled_search_modules = variable_get('search_active_modules', array());

  // If node search is enabled, core is invoking it.
  if (isset($enabled_search_modules['node']) && $enabled_search_modules['node'] === 'node') {
    return;
  }
  else {
    $ds_search_type = variable_get('ds_search_type', 'node');
    if ($ds_search_type != 'node') {
      return;
    }
  }
  $result = module_invoke('node', $hook);
  return $result;
}