(fix): save-restriction for db update (#1016)
This commit is contained in:
parent
c437052b4b
commit
6d03e7626d
1 changed files with 9 additions and 11 deletions
|
@ -455,17 +455,15 @@ connections, nil is returned."
|
||||||
(find-file-noselect file-path t))
|
(find-file-noselect file-path t))
|
||||||
(current-buffer))))
|
(current-buffer))))
|
||||||
(with-current-buffer buf
|
(with-current-buffer buf
|
||||||
(save-excursion
|
(org-with-wide-buffer
|
||||||
(save-restriction
|
(emacsql-with-transaction (org-roam-db)
|
||||||
(widen)
|
(org-roam-db--update-meta)
|
||||||
(emacsql-with-transaction (org-roam-db)
|
(org-roam-db--update-tags)
|
||||||
(org-roam-db--update-meta)
|
(org-roam-db--update-titles)
|
||||||
(org-roam-db--update-tags)
|
(org-roam-db--update-refs)
|
||||||
(org-roam-db--update-titles)
|
(org-roam-db--update-headlines)
|
||||||
(org-roam-db--update-refs)
|
(org-roam-db--update-links)))
|
||||||
(org-roam-db--update-headlines)
|
(org-roam-buffer--update-maybe :redisplay t)))))
|
||||||
(org-roam-db--update-links)))
|
|
||||||
(org-roam-buffer--update-maybe :redisplay t))))))
|
|
||||||
|
|
||||||
(defun org-roam-db-build-cache (&optional force)
|
(defun org-roam-db-build-cache (&optional force)
|
||||||
"Build the cache for `org-roam-directory'.
|
"Build the cache for `org-roam-directory'.
|
||||||
|
|
Loading…
Reference in a new issue