Skip to content

Commit

Permalink
fix(parser): mjml2html is not a function
Browse files Browse the repository at this point in the history
  • Loading branch information
ndvo committed Mar 16, 2021
1 parent cd70168 commit fcab579
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/parser.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import Twig from "twig";
import pkg from 'mjml';
const { mjml2html } = pkg;
import mjml from "mjml";
import { htmlToText } from "html-to-text";
import { config } from "../config.js";

Expand Down Expand Up @@ -78,7 +77,7 @@ function folder2message(message, subscription, cfg = config) {
* @returns {string} the html content.
*/
function processMjml(content) {
return mjml2html(content, { validationLevel: "strict" });
return mjml(content, { validationLevel: "strict" });
}

function plainTextVersion(content) {
Expand Down

0 comments on commit fcab579

Please sign in to comment.