Skip to content

Commit 0657a1e

Browse files
committed
chore: fix memo editor cache
1 parent 48546f0 commit 0657a1e

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

web/src/components/MemoEditor/index.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -349,6 +349,7 @@ const MemoEditor = (props: Props) => {
349349
toast.error(error.details);
350350
}
351351

352+
localStorage.removeItem(contentCacheKey);
352353
setState((state) => {
353354
return {
354355
...state,

web/src/pages/MemoDetail.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ const MemoDetail = () => {
6666
placeholder: t("editor.add-your-comment-here"),
6767
parentMemoName: memo.name,
6868
onConfirm: handleCommentCreated,
69+
cacheKey: `${memo.name}-${memo.updateTime}-comment`,
6970
});
7071
};
7172

0 commit comments

Comments
 (0)