chore: Remove 'attachments' option from mailer
This commit is contained in:
parent
f389ac6414
commit
9a875920ac
|
@ -2,7 +2,6 @@
|
||||||
|
|
||||||
exports[`Mailer #welcome 1`] = `
|
exports[`Mailer #welcome 1`] = `
|
||||||
Object {
|
Object {
|
||||||
"attachments": undefined,
|
|
||||||
"from": "hello@example.com",
|
"from": "hello@example.com",
|
||||||
"html": "
|
"html": "
|
||||||
<!DOCTYPE html PUBLIC \\"-//W3C//DTD XHTML 1.0 Strict//EN\\" \\"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd\\">
|
<!DOCTYPE html PUBLIC \\"-//W3C//DTD XHTML 1.0 Strict//EN\\" \\"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd\\">
|
||||||
|
|
|
@ -47,7 +47,6 @@ export type EmailSendOptions = {
|
||||||
text: string,
|
text: string,
|
||||||
html: React.Node,
|
html: React.Node,
|
||||||
headCSS?: string,
|
headCSS?: string,
|
||||||
attachments?: Object[],
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -137,7 +136,6 @@ export class Mailer {
|
||||||
subject: data.title,
|
subject: data.title,
|
||||||
html: html,
|
html: html,
|
||||||
text: data.text,
|
text: data.text,
|
||||||
attachments: data.attachments,
|
|
||||||
});
|
});
|
||||||
|
|
||||||
if (useTestEmailService) {
|
if (useTestEmailService) {
|
||||||
|
@ -163,15 +161,9 @@ export class Mailer {
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
exportSuccess = async (opts: {
|
exportSuccess = async (opts: { to: string, id: string, teamUrl: string }) => {
|
||||||
to: string,
|
|
||||||
attachments?: Object[],
|
|
||||||
id: string,
|
|
||||||
teamUrl: string,
|
|
||||||
}) => {
|
|
||||||
this.sendMail({
|
this.sendMail({
|
||||||
to: opts.to,
|
to: opts.to,
|
||||||
attachments: opts.attachments,
|
|
||||||
title: "Your requested export",
|
title: "Your requested export",
|
||||||
previewText: "Here's your request data export from Outline",
|
previewText: "Here's your request data export from Outline",
|
||||||
html: <ExportSuccessEmail id={opts.id} teamUrl={opts.teamUrl} />,
|
html: <ExportSuccessEmail id={opts.id} teamUrl={opts.teamUrl} />,
|
||||||
|
@ -179,14 +171,9 @@ export class Mailer {
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
exportFailure = async (opts: {
|
exportFailure = async (opts: { to: string, teamUrl: string }) => {
|
||||||
to: string,
|
|
||||||
attachments?: Object[],
|
|
||||||
teamUrl: string,
|
|
||||||
}) => {
|
|
||||||
this.sendMail({
|
this.sendMail({
|
||||||
to: opts.to,
|
to: opts.to,
|
||||||
attachments: opts.attachments,
|
|
||||||
title: "Your requested export",
|
title: "Your requested export",
|
||||||
previewText: "Sorry, your requested data export has failed",
|
previewText: "Sorry, your requested data export has failed",
|
||||||
html: <ExportFailureEmail teamUrl={opts.teamUrl} />,
|
html: <ExportFailureEmail teamUrl={opts.teamUrl} />,
|
||||||
|
|
Reference in New Issue