fix: remove-property!

pull/1735/head
Tienson Qin 2021-04-30 19:31:18 +08:00
parent fafce3f69f
commit 7de23f1397
2 changed files with 2 additions and 2 deletions

View File

@ -274,7 +274,7 @@
(let [format (or format :markdown)
key (string/lower-case (name key))
remove-f (if first? util/remove-first remove)]
(if-not (and (= format :org) (contains-properties? content))
(if (and (= format :org) (not (contains-properties? content)))
content
(let [lines (->> (string/split-lines content)
(remove-f (fn [line]

View File

@ -99,7 +99,7 @@
(defn remove-id-property
[]
(are [x y] (= (text/remove-id-property! x) y)
(are [x y] (= (text/remove-id-property! :org x) y)
"hello\n:PROPERTIES:\n:id: f9873a81-07b9-4246-b910-53a6f5ec7e04\n:END:\n"
"hello\n:PROPERTIES:\n:END:"