From 828d74e5bf76b8d686f161499dfa7b984bf0a166 Mon Sep 17 00:00:00 2001 From: David Schroeder Date: Sat, 2 Dec 2023 14:12:34 -0600 Subject: [PATCH] Update sites.inc --- inc/sites.inc | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/inc/sites.inc b/inc/sites.inc index 88d329e0..f1c22934 100755 --- a/inc/sites.inc +++ b/inc/sites.inc @@ -560,12 +560,8 @@ SITEINFO(){ gosite=${NM_NGINXPATH[${RUN_NODE_TYPE}]}/sites-enabled declare -A SITELIST if [ "${gosite}" != "" ]; then - gofor=false - [ "${SEARCH}" != "0" ] && [ -f "${gosite}/*${SEARCH,,}*.conf" ] && gofor=true - [ "${SEARCH}" == "0" ] && [ -f ${gosite}/*.conf ] && gofor=true - - if [ "${gofor}" == "true" ]; then - [ "${SEARCH}" != "0" ] && sites=$(find ${gosite}/*${SEARCH,,}*.conf) || sites=$(find ${gosite}/*.conf) + [ "${SEARCH}" != "0" ] && sites=$(find -s ${gosite}/*${SEARCH,,}*.conf) || sites=$(find -s ${gosite}/*.conf) + if [ "${sites}" != "" ]; then i=1 for sitefile in ${sites[@]}; do SITENAME=${sitefile##*/}; SITENAME=${SITENAME/.conf/}