diff --git a/modules/lang/org/autoload/org.el b/modules/lang/org/autoload/org.el index 66cc3f5b8..c74c10821 100644 --- a/modules/lang/org/autoload/org.el +++ b/modules/lang/org/autoload/org.el @@ -83,7 +83,11 @@ If on a: (org-toggle-checkbox (if (equal match "[ ]") '(16))))) (`headline - (cond ((org-element-property :todo-type context) + (cond ((and (fboundp 'toc-org-insert-toc) + (member "TOC" (org-get-tags))) + (toc-org-insert-toc) + (message "Updating table of contents")) + ((org-element-property :todo-type context) (org-todo (if (eq (org-element-property :todo-type context) 'done) (or (car (+org-get-todo-keywords-for (org-element-property :todo-keyword context)))