From fa62f1d514baefae3b3c92077774d18f918f0faa Mon Sep 17 00:00:00 2001 From: DIYgod Date: Tue, 20 Feb 2024 00:30:45 +0800 Subject: [PATCH] fix: post editor editing status not updated --- .../dashboard/[subdomain]/editor/post-editor.tsx | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/src/app/[locale]/dashboard/[subdomain]/editor/post-editor.tsx b/src/app/[locale]/dashboard/[subdomain]/editor/post-editor.tsx index 8c77e96870..e69feb99fc 100644 --- a/src/app/[locale]/dashboard/[subdomain]/editor/post-editor.tsx +++ b/src/app/[locale]/dashboard/[subdomain]/editor/post-editor.tsx @@ -354,14 +354,11 @@ export default function PostEditor() { [setView], ) - const onChange = useCallback( - (value: string) => { - updateValue({ - content: value, - }) - }, - [updateValue], - ) + const onChange = (value: string) => { + updateValue({ + content: value, + }) + } const onPreviewButtonClick = useCallback(() => { window.open(