Skip to content

Commit

Permalink
fix: skip any empty title
Browse files Browse the repository at this point in the history
  • Loading branch information
mcwarman committed Dec 23, 2024
1 parent 23b7c1a commit 0a3445c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions assets/js/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,7 @@ Source:
{{ $len := (len $list) -}}

{{ range $index, $element := $list -}}
{{ if not (eq .Title "") -}}
index.add(
{
id: {{ $index }},
Expand All @@ -124,6 +125,7 @@ Source:
content: {{ .Plain | jsonify }}
}
);
{{ end -}}
{{ end -}}

search.addEventListener('input', show_results, true);
Expand Down

0 comments on commit 0a3445c

Please sign in to comment.