diff --git a/src/mfm/html-to-mfm.ts b/src/mfm/html-to-mfm.ts index 540635036..daa228ec5 100644 --- a/src/mfm/html-to-mfm.ts +++ b/src/mfm/html-to-mfm.ts @@ -1,6 +1,8 @@ const parse5 = require('parse5'); export default function(html: string): string { + if (html == null) return null; + const dom = parse5.parseFragment(html); let text = '';