org-persist-write-all: Fix when BUFFER is nil

This commit is contained in:
Ihor Radchenko 2021-11-15 08:34:21 +08:00
parent 2bbac432a8
commit fefb867d91
No known key found for this signature in database
GPG Key ID: 6470762A7DA11D8B
1 changed files with 3 additions and 1 deletions

View File

@ -218,7 +218,9 @@ When BUFFER is `all', unregister VAR in all buffers."
(not buffer))
(and (plist-get index :path)
(get-file-buffer (plist-get index :path))
(equal (buffer-file-name buffer)
(equal (buffer-file-name
(or buffer
(get-file-buffer (plist-get index :path))))
(plist-get index :path))))
(org-persist-write (plist-get index :variable)
(when (plist-get index :path)