Skip to content

Commit

Permalink
Changed: the html-to-text import and fixed deprecation for it
Browse files Browse the repository at this point in the history
  • Loading branch information
BlackCubes committed Mar 3, 2021
1 parent c6f73e2 commit edd4330
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions utils/email.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const htmlToText = require('html-to-text');
const { htmlToText } = require('html-to-text');
const nodemailer = require('nodemailer');
const pug = require('pug');

Expand Down Expand Up @@ -49,7 +49,7 @@ module.exports = class Email {
to: this.to,
subject,
html,
text: htmlToText.fromString(html)
text: htmlToText(html)
};

await this.newTransport().sendMail(mailOptions);
Expand Down

0 comments on commit edd4330

Please sign in to comment.