Skip to content

Commit

Permalink
fix org-roam-capture
Browse files Browse the repository at this point in the history
  • Loading branch information
jethrokuan committed Apr 8, 2021
1 parent d641ad4 commit 467b165
Showing 1 changed file with 7 additions and 11 deletions.
18 changes: 7 additions & 11 deletions org-roam-capture.el
Expand Up @@ -541,17 +541,13 @@ This uses the templates defined at `org-roam-capture-templates'.
Arguments GOTO and KEYS see `org-capture'."
(interactive "P")
(let ((node (org-roam-node-read)))
;; TODO: fix this
(if (org-roam-node-id node)
(condition-case err
(org-roam-capture--capture goto keys
:info `((title . ,(org-roam-node-title node))
(slug . ,(funcall org-roam-title-to-slug-function
(org-roam-node-title node)))
(file . ,(org-roam-node-file node)))
:context 'capture)
(error (user-error "%s. Please adjust `org-roam-capture-templates'"
(error-message-string err)))))))
(org-roam-capture--capture :goto goto
:keys keys
:info `((title . ,(org-roam-node-title node))
(slug . ,(funcall org-roam-title-to-slug-function
(org-roam-node-title node)))
(file . ,(org-roam-node-file node)))
:context 'capture)))

(provide 'org-roam-capture)

Expand Down

0 comments on commit 467b165

Please sign in to comment.