Skip to content

Commit

Permalink
Update algolia-search-scripts.html (mmistakes#3102)
Browse files Browse the repository at this point in the history
Fix issue mmistakes#3101
  • Loading branch information
FavorMylikes authored and chukycheese committed Sep 18, 2023
1 parent 7fefbcb commit ce7c004
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions _includes/search/algolia-search-scripts.html
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,9 @@

const hitTemplate = function(hit) {
const url = hit.url;
const title = hit._highlightResult.title.value;
const content = hit._highlightResult.html.value;
const hightlight = hit._highlightResult;
const title = hightlight.title && hightlight.title.value || "";
const content = hightlight.html && hightlight.html.value || "";

return `
<div class="list__item">
Expand Down

0 comments on commit ce7c004

Please sign in to comment.