From f9109d7eb3ac302bdd01691a7af0ad192e0072bf Mon Sep 17 00:00:00 2001 From: Kartikeya Saini Date: Sat, 25 Nov 2023 16:40:04 +0530 Subject: [PATCH] Edit and Add blogs hold different cache v3 --- src/app/components/Editor.jsx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/app/components/Editor.jsx b/src/app/components/Editor.jsx index 5d72244..54ed9e1 100644 --- a/src/app/components/Editor.jsx +++ b/src/app/components/Editor.jsx @@ -89,7 +89,9 @@ export default function Editor({ let storedValue = ""; if (typeof window !== "undefined") { - sessionStorage.getItem("addBlog") ? sessionStorage.getItem("addBlog") : ""; + storedValue = sessionStorage.getItem("addBlog") + ? sessionStorage.getItem("addBlog") + : ""; } const [value, setValue] = React.useState(