From e9bb2b8721a5a47baa5b41ddead1238ea2a23221 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Paul=20H=C3=A4nsch?= Date: Wed, 7 Feb 2024 13:24:19 +0100 Subject: [PATCH] search list: check if page content exists --- handlers/40_search.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/handlers/40_search.sh b/handlers/40_search.sh index a4d91a8..0385457 100644 --- a/handlers/40_search.sh +++ b/handlers/40_search.sh @@ -69,7 +69,7 @@ for w in ${words}; do while read date doc freq num total; do P="$_DATA/pages$(UNSTRING "$doc")" d="$(stat -c %Y -- "$P/#index.flag" 2>&-)" - [ "$d" -le "$date" ] 2>&- || continue + [ "$d" -le "$date" -a -f "$P/#page.md" ] 2>&- || continue printf '%s %f\n' "$doc" "$freq" done <"$I/$w" -- 2.39.2