Browse Source

Quote echo $data in _porkbun_rest

Quote echo $data in _porkbun_rest to avoid
brace expansion under ksh (OpenBSD).
pull/5041/head
Jesse Miller 8 months ago
parent
commit
92d37f6eaf
  1. 2
      dnsapi/dns_porkbun.sh

2
dnsapi/dns_porkbun.sh

@ -134,7 +134,7 @@ _porkbun_rest() {
api_key_trimmed=$(echo "$PORKBUN_API_KEY" | tr -d '"')
secret_api_key_trimmed=$(echo "$PORKBUN_SECRET_API_KEY" | tr -d '"')
test -z "$data" && data="{" || data="$(echo $data | cut -d'}' -f1),"
test -z "$data" && data="{" || data="$(echo "$data" | cut -d'}' -f1),"
data="$data\"apikey\":\"$api_key_trimmed\",\"secretapikey\":\"$secret_api_key_trimmed\"}"
export _H1="Content-Type: application/json"

Loading…
Cancel
Save