aboutsummaryrefslogtreecommitdiff
path: root/mod/search/search_hooks.php
diff options
context:
space:
mode:
Diffstat (limited to 'mod/search/search_hooks.php')
-rw-r--r--mod/search/search_hooks.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/mod/search/search_hooks.php b/mod/search/search_hooks.php
index ae8433409..428d6f700 100644
--- a/mod/search/search_hooks.php
+++ b/mod/search/search_hooks.php
@@ -93,11 +93,11 @@ function search_groups_hook($hook, $type, $value, $params) {
// add the volatile data for why these entities have been returned.
foreach ($entities as $entity) {
- $description = search_get_highlighted_relevant_substrings($entity->description, $query);
- $entity->setVolatileData('search_matched_title', $description);
-
$name = search_get_highlighted_relevant_substrings($entity->name, $query);
- $entity->setVolatileData('search_matched_description', $name);
+ $entity->setVolatileData('search_matched_title', $name);
+
+ $description = search_get_highlighted_relevant_substrings($entity->description, $query);
+ $entity->setVolatileData('search_matched_description', $description);
}
return array(