diff --git a/src/EditorFactory.js b/src/EditorFactory.js index 54424c78d48..dd597927710 100644 --- a/src/EditorFactory.js +++ b/src/EditorFactory.js @@ -140,7 +140,7 @@ const serializePlainText = (tiptap) => { const doc = tiptap.getJSON() if (doc.content.length !== 1 || typeof doc.content[0].content === 'undefined' || doc.content[0].content.length !== 1) { - if (doc.content[0].type === 'code_block' && typeof doc.content[0].content === 'undefined') { + if (doc.content[0].type === 'codeBlock' && typeof doc.content[0].content === 'undefined') { return '' } throw new SerializeException('Failed to serialize document to plain text')