Răsfoiți Sursa

proper check for fastdl

lrob 10 ani în urmă
părinte
comite
18707efe0a
1 a modificat fișierele cu 2 adăugiri și 2 ștergeri
  1. 2 2
      functions/command_fastdl.sh

+ 2 - 2
functions/command_fastdl.sh

@@ -70,7 +70,7 @@ fi
 if [ ! -d "${fastdldir}" ]; then
 if [ ! -d "${fastdldir}" ]; then
 	# No folder, won't ask for removing old ones
 	# No folder, won't ask for removing old ones
 	newfastdl=1
 	newfastdl=1
-	fn_printdots "Creating FastDL fastdl directory"
+	fn_printdots "Creating fastdl directory"
 	sleep 1
 	sleep 1
 	mkdir "${fastdldir}"
 	mkdir "${fastdldir}"
 	fn_printok "Created fastdl directory"
 	fn_printok "Created fastdl directory"
@@ -90,7 +90,7 @@ fn_scriptlog "Configuration"
 sleep 2
 sleep 2
 echo -en "\n"
 echo -en "\n"
 # Prompt for clearing old files if folder was already here
 # Prompt for clearing old files if folder was already here
-if [ -z "${newfastdl}" ] && [ "${newfastdl}" == "0" ]; then
+if [ -d "${newfastdl}" ] && [ "${newfastdl}" == "0" ]; then
 	fn_printdots
 	fn_printdots
 	while true; do
 	while true; do
 		read -e -i "y" -p "Clear old FastDL files? [Y/n]" yn
 		read -e -i "y" -p "Clear old FastDL files? [Y/n]" yn