We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 730fa5e commit 1b40291Copy full SHA for 1b40291
packages/ckeditor5/src/plugin.js
@@ -523,8 +523,10 @@ export default class MathType extends Plugin {
523
// If we found a formula image, we should find MathML data, and then substitute the entire image.
524
const regexp = /«math\b[^»]*»(.*?)«\/math»/g;
525
const safexml = formula.match(regexp);
526
- let decodeXML = MathML.safeXmlDecode(safexml[0]);
527
- modifiedData = modifiedData.replace(formula, decodeXML);
+ if(safexml !== null) {
+ let decodeXML = MathML.safeXmlDecode(safexml[0]);
528
+ modifiedData = modifiedData.replace(formula, decodeXML);
529
+ }
530
}
531
});
532
0 commit comments