tindex.dcgi: fix logic with no results - recipes - various cooking recipes
(HTM) git clone git://src.adamsgaard.dk/recipes
(DIR) Log
(DIR) Files
(DIR) Refs
(DIR) Submodules
---
(DIR) commit 65b22fe4f2d51c690c8e1a9e14f35b9b7c3cd693
(DIR) parent c9795931746ecb8a49a7408e49848be90581898e
(HTM) Author: Anders Damsgaard <anders@adamsgaard.dk>
Date: Fri, 27 Aug 2021 20:00:01 +0200
index.dcgi: fix logic with no results
Diffstat:
M index.dcgi | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
(DIR) diff --git a/index.dcgi b/index.dcgi
t@@ -44,7 +44,7 @@ then
fi
n="$(printf '%s\n' "$results" | wc -l)"
- if [ $n -gt 0 ];
+ if [ $n -gt 0 ] && [ -n "$results" ];
then
if [ $n -gt 1 ];
then