12345678910111213141516171819202122232425262728293031323334353637 |
- import config from "config";
- import mail from "../index";
- export default (to, username, code, cb) => {
- const data = {
- from: "Musare <noreply@musare.com>",
- to,
- subject: "Please verify your email",
- html: `
- Hello there ${username},
- <br>
- <br>
- To verify your email, please visit <a href="${config.get("serverDomain")}/auth/verify_email?code=${code}">${config.get(
- "serverDomain"
- )}/auth/verify_email?code=${code}</a>.
- `
- };
- mail.runJob("SEND_MAIL", { data })
- .then(() => {
- cb();
- })
- .catch(err => {
- cb(err);
- });
- };
|