mirror of
https://github.com/logseq/logseq.git
synced 2026-04-25 22:54:48 +00:00
fix: unable to add a comment using # in codeblocks
fixes https://github.com/logseq/db-test/issues/168
This commit is contained in:
@@ -77,13 +77,13 @@ and handles unexpected failure."
|
||||
(let [block (dissoc block :block/pre-block?)
|
||||
format (or format :markdown)
|
||||
parse-config (mldoc/get-default-config format)
|
||||
ast (format/to-edn title format parse-config)
|
||||
;; Disable extraction for display-type blocks as there isn't a reason to have
|
||||
;; it enabled yet and can cause visible bugs when '#' is used
|
||||
blocks (if (and (config/db-based-graph? (state/get-current-repo))
|
||||
(:logseq.property.node/display-type block))
|
||||
[block]
|
||||
(extract-blocks ast title format {:parse-block block}))
|
||||
(let [ast (format/to-edn title format parse-config)]
|
||||
(extract-blocks ast title format {:parse-block block})))
|
||||
new-block (first blocks)
|
||||
block (cond->
|
||||
(merge block new-block)
|
||||
|
||||
Reference in New Issue
Block a user