fix bash unuse vars
This commit is contained in:
parent
cbb1c713f4
commit
c145fb71bf
@ -37,7 +37,6 @@ dns_arvan_add() {
|
|||||||
_info "Adding record"
|
_info "Adding record"
|
||||||
if _arvan_rest POST "$_domain/dns-records" "{\"type\":\"TXT\",\"name\":\"$_sub_domain\",\"value\":{\"text\":\"$txtvalue\"},\"ttl\":120}"; then
|
if _arvan_rest POST "$_domain/dns-records" "{\"type\":\"TXT\",\"name\":\"$_sub_domain\",\"value\":{\"text\":\"$txtvalue\"},\"ttl\":120}"; then
|
||||||
if _contains "$response" "$txtvalue"; then
|
if _contains "$response" "$txtvalue"; then
|
||||||
TXT_RECORD_ID=$(echo "$response" | _egrep_o ".\"id\":\"[^\"]*\"" | cut -d : -f 2| tr -d \")
|
|
||||||
_info "response id is $response"
|
_info "response id is $response"
|
||||||
_info "Added, OK"
|
_info "Added, OK"
|
||||||
return 0
|
return 0
|
||||||
@ -50,7 +49,7 @@ dns_arvan_add() {
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
_err "Add txt record error."
|
_err "Add txt record error."
|
||||||
return 1
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
#Usage: fulldomain txtvalue
|
#Usage: fulldomain txtvalue
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user