Skip to content

Commit

Permalink
Update postToMap.sh: add trailing "/" to "remotewebsiteurl"
Browse files Browse the repository at this point in the history
Without a trailing "/" we may get a "Moved permanently" message rather than the header for the web page, which makes the code think it's an error.
  • Loading branch information
EricClaeys authored Jun 7, 2024
1 parent 08bd316 commit d07062f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions scripts/postToMap.sh
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,11 @@ if [[ ${DELETE} == "true" ]]; then
else
LOCATION="$( settings ".location" )"
OWNER="$( settings ".owner" )"

WEBSITE_URL="$( settings ".remotewebsiteurl" )"
# Without a trailing "/" we may get a "Moved permanently" message.
[[ ${WEBSITE_URL: -1:1} != "/" ]] && WEBSITE_URL="${WEBSITE_URL}/"

IMAGE_URL="$( settings ".remotewebsiteimageurl" )"
CAMERA="$( settings ".camera" )"
LENS="$( settings ".lens" )"
Expand Down

0 comments on commit d07062f

Please sign in to comment.