You are here

function _search_api_autocomplete_index_uses_translation in Search API Autocomplete 7

Determines if the "Transliteration" processor is enabled for the given index.

Parameters

SearchApiIndex $index: The index to check.

Return value

bool TRUE if transliteration is enabled, FALSE otherwise.

1 call to _search_api_autocomplete_index_uses_translation()
search_api_autocomplete_autocomplete in ./search_api_autocomplete.pages.inc
Page callback for getting autocomplete suggestions.

File

./search_api_autocomplete.pages.inc, line 135
Contains page callbacks and theme functions for the frontend UI.

Code

function _search_api_autocomplete_index_uses_translation(SearchApiIndex $index) {
  if (module_exists('transliteration')) {
    $processors = $index->options['processors'];
    return !empty($processors['search_api_transliteration']['status']);
  }
  return FALSE;
}