(fix): replace if with when (#632)

This commit is contained in:
Leo Vivier
2020-05-15 14:23:06 +02:00
committed by GitHub
parent f390593cfb
commit 9961a22a8c

View File

@@ -590,9 +590,8 @@ plist containing the path to the file, and the original title."
(let ((titles (or titles (list (org-roam--path-to-slug file-path)))))
(dolist (title titles)
(let ((k (concat
(if tags
(concat "(" (s-join org-roam-tag-separator tags) ") ")
"")
(when tags
(format "(%s) " (s-join org-roam-tag-separator tags)))
title))
(v (list :path file-path :title title)))
(puthash k v ht))))))