Hi,

This code does not work [1], find attached a patch proposal

Cheers,
pinmacs

[1] https://orgmode.org/worg/org-hacks.html#remove-empty-property-drawers
From fd4d90fccaf5447b1c1dadedfff27703b48aff69 Mon Sep 17 00:00:00 2001
From: pinmacs <[email protected]>
Date: Fri, 12 Dec 2025 20:54:26 +0100
Subject: [PATCH] org-hacks: bugfix `dmj:org:remove-empty-property-drawers'

new version of org-remove-empty-drawer-at requires only 1 argument
---
 org-hacks.org | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/org-hacks.org b/org-hacks.org
index 63b36d7e..59ef5165 100644
--- a/org-hacks.org
+++ b/org-hacks.org
@@ -1538,7 +1538,7 @@ headline or the #+FILETAGS: statement.
 David Maus proposed this:
 
 #+begin_src emacs-lisp
-(defun dmj:org:remove-empty-propert-drawers ()
+(defun dmj:org:remove-empty-property-drawers ()
   "*Remove all empty property drawers in current file."
   (interactive)
   (unless (eq major-mode 'org-mode)
@@ -1547,7 +1547,7 @@ David Maus proposed this:
     (goto-char (point-min))
     (while (re-search-forward ":PROPERTIES:" nil t)
       (save-excursion
-	(org-remove-empty-drawer-at "PROPERTIES" (match-beginning 0))))))
+	(org-remove-empty-drawer-at (match-beginning 0))))))
 #+end_src
 
 *** Group task list by a property
-- 
2.39.5

Reply via email to