Skip to main content
deleted 42 characters in body
Source Link
/**
 * Implements hook_query_TAG_alter(): tag search_$type with $type node_search.
 */    
function hook_query_search_node_search_alter(&$query) {
      $language = \Drupal::languageManager()->getCurrentLanguage()->getId();
      $query->condition('i.langcode', [$language, 'und', 'zxx'], 'IN');
}
/**
 * Implements hook_query_TAG_alter(): tag search_$type with $type node_search.
 */    
function hook_query_search_node_search_alter(&$query) {
      $language = \Drupal::languageManager()->getCurrentLanguage()->getId();
      $query->condition('i.langcode', [$language, 'und', 'zxx'], 'IN');
}
/**
 * Implements hook_query_TAG_alter()
 */    
function hook_query_search_node_search_alter(&$query) {
      $language = \Drupal::languageManager()->getCurrentLanguage()->getId();
      $query->condition('i.langcode', [$language, 'und', 'zxx'], 'IN');
}
Source Link

/**
 * Implements hook_query_TAG_alter(): tag search_$type with $type node_search.
 */    
function hook_query_search_node_search_alter(&$query) {
      $language = \Drupal::languageManager()->getCurrentLanguage()->getId();
      $query->condition('i.langcode', [$language, 'und', 'zxx'], 'IN');
}