mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-11-24 06:35:49 +03:00
Updated sender address for ownership verification emails to new address
no issue - We used existing "from" address as sender for mails sent to new email address for verification, but that breaks the flow to update if the current "from" address has DMARC policy set. - This updates the flow to always send the ownership verification email TO the new address and FROM the new address which both verifies the email deliverability for new address and ownership
This commit is contained in:
parent
8d022ecfb5
commit
806d0f8e21
@ -71,6 +71,20 @@ function createSettingsInstance(config) {
|
||||
});
|
||||
|
||||
const sendEmailAddressUpdateMagicLink = ({email, payload = {}, type = 'fromAddressUpdate'}) => {
|
||||
magicLinkService.transporter = {
|
||||
sendMail(message) {
|
||||
if (process.env.NODE_ENV !== 'production') {
|
||||
logging.warn(message.text);
|
||||
}
|
||||
let msg = Object.assign({
|
||||
from: email,
|
||||
subject: 'Update email address',
|
||||
forceTextContent: true
|
||||
}, message);
|
||||
|
||||
return ghostMailer.send(msg);
|
||||
}
|
||||
};
|
||||
return magicLinkService.sendMagicLink({email, payload, subject: email, type});
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user