mirror of
https://github.com/plantroon/acme.sh.git
synced 2024-12-25 14:41:40 +00:00
Merge pull request #4310 from mystix/patch-1
Prevent erasure of saved access token on DNS removal
This commit is contained in:
commit
f0b5f592dc
@ -18,15 +18,15 @@ dns_netlify_add() {
|
|||||||
NETLIFY_ACCESS_TOKEN=""
|
NETLIFY_ACCESS_TOKEN=""
|
||||||
_err "Please specify your Netlify Access Token and try again."
|
_err "Please specify your Netlify Access Token and try again."
|
||||||
return 1
|
return 1
|
||||||
|
else
|
||||||
|
_saveaccountconf_mutable NETLIFY_ACCESS_TOKEN "$NETLIFY_ACCESS_TOKEN"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
_info "Using Netlify"
|
_info "Using Netlify"
|
||||||
_debug fulldomain "$fulldomain"
|
_debug fulldomain "$fulldomain"
|
||||||
_debug txtvalue "$txtvalue"
|
_debug txtvalue "$txtvalue"
|
||||||
|
|
||||||
_saveaccountconf_mutable NETLIFY_ACCESS_TOKEN "$NETLIFY_ACCESS_TOKEN"
|
if ! _get_root "$fulldomain"; then
|
||||||
|
|
||||||
if ! _get_root "$fulldomain" "$accesstoken"; then
|
|
||||||
_err "invalid domain"
|
_err "invalid domain"
|
||||||
return 1
|
return 1
|
||||||
fi
|
fi
|
||||||
@ -62,9 +62,9 @@ dns_netlify_rm() {
|
|||||||
_debug txtdomain "$txtdomain"
|
_debug txtdomain "$txtdomain"
|
||||||
_debug txt "$txt"
|
_debug txt "$txt"
|
||||||
|
|
||||||
_saveaccountconf_mutable NETLIFY_ACCESS_TOKEN "$NETLIFY_ACCESS_TOKEN"
|
NETLIFY_ACCESS_TOKEN="${NETLIFY_ACCESS_TOKEN:-$(_readaccountconf_mutable NETLIFY_ACCESS_TOKEN)}"
|
||||||
|
|
||||||
if ! _get_root "$txtdomain" "$accesstoken"; then
|
if ! _get_root "$txtdomain"; then
|
||||||
_err "invalid domain"
|
_err "invalid domain"
|
||||||
return 1
|
return 1
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user