Skip to content

Commit

Permalink
Update email text because admins can make changes (#998)
Browse files Browse the repository at this point in the history
  • Loading branch information
lognaturel authored Sep 23, 2023
1 parent 0b1272f commit efc6b20
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions lib/formats/mail.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ const messages = {
accountCreatedForOidc: message('ODK Central account created', '<html>Hello!<p>An account has been provisioned for you on an ODK Central data collection server.</p><p>If this message is unexpected, simply ignore it. Otherwise, please go to <a href="{{{domain}}}">{{{domain}}}</a> to sign in.</p></html>'),

// Notifies a user that their account's email has been changed
accountEmailChanged: message('ODK Central account email changed', '<html>Hello!<p><p>We are emailing because you have an ODK Central account, and somebody has just changed the email address associated with the account from this one you are reading right now ({{oldEmail}}) to a new address ({{newEmail}}).</p><p>If this was you, please feel free to ignore this email. Otherwise, please contact your local ODK system administrator immediately.</p></html>'),
accountEmailChanged: message('ODK Central account email changed', '<html>Hello!<p><p>We are emailing because you have an ODK Central account, and somebody has just changed the email address associated with the account from this one you are reading right now ({{oldEmail}}) to a new address ({{newEmail}}).</p><p>If this is expected, you can ignore this email. If it is not expected, please contact your ODK system administrator immediately.</p></html>'),

// Notifies a user that a password reset has been initiated for their email;
// gives them the link required to set their password.
Expand All @@ -48,7 +48,7 @@ const messages = {
accountResetDeleted: message('ODK Central account password reset', '<html>Hello!<p>A password reset has been requested for this email address, but the account has been deleted.</p><p>If this message is unexpected, simply ignore it. Otherwise, please double check the email address given for your account, and try contacting your ODK system administrator.</p></html>'),

// Notifies a user that their password has been changed
accountPasswordChanged: message('ODK Central account password change', '<html>Hello!<p>We are emailing because you have an ODK Central account, and somebody has just changed its password.</p><p>If this was you, please feel free to ignore this email.</p><p>Otherwise, please contact your local ODK system administrator immediately.</p></html>')
accountPasswordChanged: message('ODK Central account password change', '<html>Hello!<p>We are emailing because you have an ODK Central account, and somebody has just changed its password.</p><p>If this is expected, you can ignore this email.</p><p>If it is not expected, please contact your ODK system administrator immediately.</p></html>')
};

module.exports = { messages };
Expand Down
2 changes: 1 addition & 1 deletion test/integration/api/users.js
Original file line number Diff line number Diff line change
Expand Up @@ -574,7 +574,7 @@ describe('api: /users', () => {
global.inbox.length.should.equal(0);
email.to.should.eql([{ address: '[email protected]', name: '' }]);
email.subject.should.equal('ODK Central account email changed');
email.html.should.equal('<html>Hello!<p><p>We are emailing because you have an ODK Central account, and somebody has just changed the email address associated with the account from this one you are reading right now ([email protected]) to a new address ([email protected]).</p><p>If this was you, please feel free to ignore this email. Otherwise, please contact your local ODK system administrator immediately.</p></html>');
email.html.should.equal('<html>Hello!<p><p>We are emailing because you have an ODK Central account, and somebody has just changed the email address associated with the account from this one you are reading right now ([email protected]) to a new address ([email protected]).</p><p>If this is expected, you can ignore this email. If it is not expected, please contact your ODK system administrator immediately.</p></html>');
})))));
}

Expand Down

0 comments on commit efc6b20

Please sign in to comment.