Skip to content

Commit

Permalink
3 => header
Browse files Browse the repository at this point in the history
  • Loading branch information
spatten committed Dec 9, 2023
1 parent 015f666 commit 2c36508
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions install-latest.sh
Original file line number Diff line number Diff line change
Expand Up @@ -256,10 +256,10 @@ http_download_curl() {
local_file=$1
source_url=$2
header=$3
if [ -n "$3" ]; then
if [ -n "$header" ]; then
HTTP_CODE=$(curl -w '%{HTTP_CODE}' -sL -H "$header" -H "Cache-Control: no-cache" -o "$local_file" "$source_url") || (log_debug "curl command failed." && return 1)
fi
if [ -z "$3" ]; then
if [ -z "$header" ]; then
HTTP_CODE=$(curl -w '%{HTTP_CODE}' -sL -H "Cache-Control: no-cache" -o "$local_file" "$source_url") || (log_debug "curl command failed." && return 1)
fi
return 0
Expand Down

0 comments on commit 2c36508

Please sign in to comment.