mirror of
https://github.com/acmesh-official/acme.sh.git
synced 2026-10-21 21:31:51 +00:00
update-account: persist the new email into the CA conf
"--update-account -m new@example.com" updated the contact on the CA but never saved it locally, so CA_EMAIL kept showing the old address on every later run. Save it in the success path like _regAccount does. https://github.com/acmesh-official/acme.sh/issues/4673
This commit is contained in:
1 parent
447dc3c7e7
commit
15a1067f1b
1 file changed
+6
@@ -4179,6 +4179,12 @@ updateaccount() {
|
|||||||
if [ "$code" = '200' ]; then
|
if [ "$code" = '200' ]; then
|
||||||
echo "$response" >"$ACCOUNT_JSON_PATH"
|
echo "$response" >"$ACCOUNT_JSON_PATH"
|
||||||
_info "Account update success for $_accUri."
|
_info "Account update success for $_accUri."
|
||||||
|
# persist the effective mailbox like _regAccount does; otherwise
|
||||||
|
# "--update-account -m new@..." updates the CA but the local conf
|
||||||
|
# keeps showing the old address (issue 4673)
|
||||||
|
if [ "$_email" ]; then
|
||||||
|
_savecaconf "CA_EMAIL" "$_email"
|
||||||
|
fi
|
||||||
|
|
||||||
ACCOUNT_THUMBPRINT="$(__calc_account_thumbprint)"
|
ACCOUNT_THUMBPRINT="$(__calc_account_thumbprint)"
|
||||||
_info "ACCOUNT_THUMBPRINT" "$ACCOUNT_THUMBPRINT"
|
_info "ACCOUNT_THUMBPRINT" "$ACCOUNT_THUMBPRINT"
|
||||||
|
|||||||