From 971181df302079e660093e2499c8ee261b2ffb2a Mon Sep 17 00:00:00 2001 From: louie Date: Wed, 31 Jan 2018 21:46:32 +0800 Subject: [PATCH] Enable Org major mode in temp buffer before using org-element --- anki-editor.el | 1 + 1 file changed, 1 insertion(+) diff --git a/anki-editor.el b/anki-editor.el index 980adea..dbcedf5 100644 --- a/anki-editor.el +++ b/anki-editor.el @@ -339,6 +339,7 @@ DECK is used when the action is note creation." (org-element-property :begin note-elem) (org-element-property :end note-elem)))) (with-temp-buffer + (org-mode) (insert content) (car (org-element-contents (org-element-parse-buffer))))) note (anki-editor--heading-to-note note-elem))