summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordaspeter2011-07-25 21:04:43 (GMT)
committer Thomas Seidl2011-07-25 21:04:43 (GMT)
commit78e922b4331dd6475b074c17fc809f3b6091fa03 (patch)
tree8cc1eb8b77869c52051035ce251a1616be7aa665
parent8552f6c6226dca7eb48aac31c97e8e545dfc32bc (diff)
Follow-up to #1064884 by das-peter: Added support for indexing non-entities.
-rw-r--r--includes/callback_bundle_filter.inc4
-rw-r--r--search_api.api.php4
2 files changed, 4 insertions, 4 deletions
diff --git a/includes/callback_bundle_filter.inc b/includes/callback_bundle_filter.inc
index 8e39200..bb2147f 100644
--- a/includes/callback_bundle_filter.inc
+++ b/includes/callback_bundle_filter.inc
@@ -11,7 +11,7 @@ class SearchApiAlterBundleFilter extends SearchApiAbstractAlterCallback {
}
public function alterItems(array &$items) {
- $info = entity_get_info($this->index->entity_type);
+ $info = entity_get_info($this->index->item_type);
if (self::hasBundles($info) && isset($this->options['bundles'])) {
$bundles = array_flip($this->options['bundles']);
$default = (bool) $this->options['default'];
@@ -25,7 +25,7 @@ class SearchApiAlterBundleFilter extends SearchApiAbstractAlterCallback {
}
public function configurationForm() {
- $info = entity_get_info($this->index->entity_type);
+ $info = entity_get_info($this->index->item_type);
if (self::hasBundles($info)) {
$options = array();
foreach ($info['bundles'] as $bundle => $bundle_info) {
diff --git a/search_api.api.php b/search_api.api.php
index 7339c57..e245a4d 100644
--- a/search_api.api.php
+++ b/search_api.api.php
@@ -227,7 +227,7 @@ function hook_search_api_index_items_alter(array &$items, SearchApiIndex $index)
unset($items[$id]);
}
}
- example_store_indexed_entity_ids($index->entity_type, array_keys($items));
+ example_store_indexed_entity_ids($index->item_type, array_keys($items));
}
/**
@@ -237,7 +237,7 @@ function hook_search_api_index_items_alter(array &$items, SearchApiIndex $index)
* The SearchApiQueryInterface object representing the search query.
*/
function hook_search_api_query_alter(SearchApiQueryInterface $query) {
- $info = entity_get_info($index->entity_type);
+ $info = entity_get_info($index->item_type);
$query->condition($info['entity keys']['id'], 0, '!=');
}