From cef72a1463b0199cdef1df6764aa791b11a38755 Mon Sep 17 00:00:00 2001 From: Tienson Qin Date: Wed, 16 Aug 2023 01:13:59 +0800 Subject: [PATCH] fix: no need to clean content for db graphs --- src/main/frontend/handler/editor.cljs | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/main/frontend/handler/editor.cljs b/src/main/frontend/handler/editor.cljs index db47114c9..a711530fd 100644 --- a/src/main/frontend/handler/editor.cljs +++ b/src/main/frontend/handler/editor.cljs @@ -1264,10 +1264,12 @@ (defn- clean-content! [repo format content] - (->> (text/remove-level-spaces content format (config/get-block-pattern format)) - (drawer/remove-logbook) - (file-property/remove-properties-when-file-based repo format) - string/trim)) + (if (config/db-based-graph? repo) + content + (some->> (text/remove-level-spaces content format (config/get-block-pattern format)) + (drawer/remove-logbook) + (file-property/remove-properties-when-file-based repo format) + string/trim))) (defn insert-command! [id command-output format {:keys [restore?]