diff --git a/oni-org/oni-org.el b/oni-org/oni-org.el index 7164040..7a95721 100644 --- a/oni-org/oni-org.el +++ b/oni-org/oni-org.el @@ -1083,10 +1083,9 @@ placed above TARGET. Otherwise it will be placed below it." (goto-char (point-min)) (org-forward-heading-same-level 1) (let* ((element (org-element-at-point-no-context)) - (element-data (when element (cadr element))) - (element-title (when element-data (map-elt element-data :raw-value))) - (contents-begin (when element-data (map-elt element-data :contents-begin))) - (contents-end (when element-data (map-elt element-data :contents-end)))) + (element-title (org-element-property :raw-value element)) + (contents-begin (org-element-property :contents-begin element)) + (contents-end (org-element-property :contents-end element))) (when contents-begin (let ((text (buffer-substring-no-properties contents-begin contents-end))) (delete-region contents-begin contents-end)