From 17bfed137ce02bc9c35c58eae2f404b21cc3c42b Mon Sep 17 00:00:00 2001 From: Andrey Antukh Date: Wed, 25 Jun 2025 20:14:33 +0200 Subject: [PATCH] :paperclip: Add better defaults for text processing on old migrations --- common/src/app/common/files/migrations.cljc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/common/src/app/common/files/migrations.cljc b/common/src/app/common/files/migrations.cljc index 800c8552f7..564fe4fc55 100644 --- a/common/src/app/common/files/migrations.cljc +++ b/common/src/app/common/files/migrations.cljc @@ -855,7 +855,7 @@ (update-object [object] (if (cfh/text-shape? object) - (update object :content #(txt/transform-nodes identity update-text-node %)) + (update object :content #(txt/transform-nodes txt/is-content-node? update-text-node %)) object)) (update-container [container] @@ -1105,7 +1105,7 @@ ;; The text shape also can has fills on the text ;; fragments so we need to fix fills there (cond-> (cfh/text-shape? object) - (update :content (partial txt/transform-nodes identity fix-fills))))) + (update :content (partial txt/transform-nodes txt/is-content-node? fix-fills))))) (update-container [container] (d/update-when container :objects d/update-vals update-object))] @@ -1407,7 +1407,7 @@ (update-object [object] (if (cfh/text-shape? object) - (update object :content (partial txt/transform-nodes identity fix-fills)) + (update object :content (partial txt/transform-nodes txt/is-content-node? fix-fills)) object)) (update-container [container]