diff --git a/packages/core/src/commands/insertContentAt.ts b/packages/core/src/commands/insertContentAt.ts index 9e39fd226..c5aa7186f 100644 --- a/packages/core/src/commands/insertContentAt.ts +++ b/packages/core/src/commands/insertContentAt.ts @@ -91,7 +91,7 @@ export const insertContentAt: RawCommands['insertContentAt'] = (position, value, // If `emitContentError` is enabled, we want to check the content for errors // but ignore them (do not remove the invalid content from the document) - if (!options.errorOnInvalidContent && editor.options.enableContentCheck && editor.options.emitContentError) { + if (!options.errorOnInvalidContent && !editor.options.enableContentCheck && editor.options.emitContentError) { try { createNodeFromContent(value, editor.schema, { parseOptions,