Bugfix for install.sh
This commit is contained in:
parent
b4778d8cf3
commit
5e48b98c5c
1 changed files with 4 additions and 4 deletions
|
|
@ -55,10 +55,10 @@ download_file() {
|
||||||
# Function to validate the API token format
|
# Function to validate the API token format
|
||||||
validate_token() {
|
validate_token() {
|
||||||
local token="$1"
|
local token="$1"
|
||||||
if [[ ! "$token" =~ ^[a-f0-9]{80}$ ]]; then
|
if [[ "$token" =~ ^[a-f0-9]{80}$ ]]; then
|
||||||
return 1
|
|
||||||
else
|
|
||||||
return 0
|
return 0
|
||||||
|
else
|
||||||
|
return 1
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -175,7 +175,7 @@ while [[ $attempts -lt $max_attempts ]]; do
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
if [[ "$valid_token" == false ]]; then
|
if [[ "$valid_token" == "false" ]]; then
|
||||||
echo -e "\nFAIL: Maximum number of attempts reached. Installation aborted!"
|
echo -e "\nFAIL: Maximum number of attempts reached. Installation aborted!"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue