From e62d790f995a3f91272b2b9036f710293646b71e Mon Sep 17 00:00:00 2001 From: Kroese Date: Fri, 3 May 2024 04:02:46 +0200 Subject: [PATCH] Update install.sh --- src/install.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/install.sh b/src/install.sh index a5072db..24c7b30 100644 --- a/src/install.sh +++ b/src/install.sh @@ -172,7 +172,8 @@ detectCustom() { if [[ "${VERSION,,}" != "http"* ]]; then file="${VERSION/\/storage\//}" [[ "$file" == "."* ]] && file="${file:1}" - CUSTOM=$(find "$STORAGE" -maxdepth 1 -type f -iname "$file" -printf "%f\n" | head -n 1) + [[ "$file" == *"/"* ]] && file="" + [ -n "$file" ] && CUSTOM=$(find "$STORAGE" -maxdepth 1 -type f -iname "$file" -printf "%f\n" | head -n 1) fi [ -z "$CUSTOM" ] && CUSTOM=$(find "$STORAGE" -maxdepth 1 -type f -iname custom.iso -printf "%f\n" | head -n 1)