mirror of
https://github.com/logseq/logseq.git
synced 2026-04-26 23:25:05 +00:00
Add some limits to tags
This commit is contained in:
@@ -87,12 +87,15 @@
|
||||
|
||||
(defn ->tags
|
||||
[tags]
|
||||
(mapv (fn [tag]
|
||||
(->> (map (fn [tag]
|
||||
(let [tag (-> (string/lower-case tag)
|
||||
(string/replace #"\s+" "-"))]
|
||||
{:db/id tag
|
||||
:tag/name tag}))
|
||||
(remove nil? tags)))
|
||||
(if (util/tag-valid? tag)
|
||||
{:db/id tag
|
||||
:tag/name tag})))
|
||||
(remove nil? tags))
|
||||
(remove nil?)
|
||||
vec))
|
||||
|
||||
(defn with-refs
|
||||
[{:keys [title body tags] :as heading}]
|
||||
|
||||
Reference in New Issue
Block a user