From 2758f8f6094bd8f5592f7f041b789e80362d17d6 Mon Sep 17 00:00:00 2001 From: Anmol Singh Bhatia Date: Fri, 31 Jan 2025 15:12:29 +0530 Subject: [PATCH] fix: page version history application error --- packages/editor/src/core/hooks/use-editor.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/editor/src/core/hooks/use-editor.ts b/packages/editor/src/core/hooks/use-editor.ts index af970b670a6..23bb5088417 100644 --- a/packages/editor/src/core/hooks/use-editor.ts +++ b/packages/editor/src/core/hooks/use-editor.ts @@ -202,7 +202,7 @@ export const useEditor = (props: CustomEditorProps) => { getDocument: () => { const documentBinary = provider?.document ? Y.encodeStateAsUpdate(provider?.document) : null; const documentHTML = editor?.getHTML() ?? "

"; - const documentJSON = editor.getJSON() ?? null; + const documentJSON = editor?.getJSON() ?? null; return { binary: documentBinary,