emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/org-contrib 2a77f1de0c 03/10: lisp/org-expiry.el: Fix comp


From: ELPA Syncer
Subject: [nongnu] elpa/org-contrib 2a77f1de0c 03/10: lisp/org-expiry.el: Fix compiler warnings
Date: Wed, 17 Jan 2024 07:00:55 -0500 (EST)

branch: elpa/org-contrib
commit 2a77f1de0cc1dbf8345ac26eed32798e779910ab
Author: Ihor Radchenko <yantar92@posteo.net>
Commit: Ihor Radchenko <yantar92@posteo.net>

    lisp/org-expiry.el: Fix compiler warnings
    
    * lisp/org-expiry.el (org-schedule):
    (org-deadline):
    (org-time-stamp): Use `define-advice' instead of `defadvice'.
    (org-expiry-process-entry): Use `called-interactively-p' instead of
    obsolete `interactive-p'.  Fix `called-interactively-p' args.
---
 lisp/org-expiry.el | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/lisp/org-expiry.el b/lisp/org-expiry.el
index 1ed2b75d84..4caf870e67 100644
--- a/lisp/org-expiry.el
+++ b/lisp/org-expiry.el
@@ -157,15 +157,15 @@ functions.  `org-expiry-deinsinuate' will deactivate 
them."
 
 ;;; Advices and insinuation:
 
-(defadvice org-schedule (after org-schedule-update-created)
+(define-advice org-schedule (:after (&rest _) org-schedule-update-created)
   "Update the creation-date property when calling `org-schedule'."
   (org-expiry-insert-created))
 
-(defadvice org-deadline (after org-deadline-update-created)
+(define-advice org-deadline (:after (&rest _) org-deadline-update-created)
   "Update the creation-date property when calling `org-deadline'."
   (org-expiry-insert-created))
 
-(defadvice org-time-stamp (after org-time-stamp-update-created)
+(define-advice org-time-stamp (:after (&rest _) org-time-stamp-update-created)
   "Update the creation-date property when calling `org-time-stamp'."
   (org-expiry-insert-created))
 
@@ -240,7 +240,7 @@ If FORCE is non-nil, don't require confirmation from the 
user.
 Otherwise rely on `org-expiry-confirm-flag' to decide."
   (interactive "P")
   (save-excursion
-    (when (called-interactively-p) (org-reveal))
+    (when (called-interactively-p 'interactive) (org-reveal))
     (when (org-expiry-expired-p)
       (org-back-to-heading)
       (looking-at org-complex-heading-regexp)
@@ -251,10 +251,10 @@ Otherwise rely on `org-expiry-confirm-flag' to decide."
        (if (or force
                (null org-expiry-confirm-flag)
                (and (eq org-expiry-confirm-flag 'interactive)
-                    (not (interactive-p)))
+                    (not (called-interactively-p 'interactive)))
                (and org-expiry-confirm-flag
                     (y-or-n-p (format "Entry expired by %d days.  Process? " 
d))))
-         (funcall org-expiry-handler-function))
+           (funcall org-expiry-handler-function))
        (delete-overlay ov)))))
 
 (defun org-expiry-process-entries (beg end)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]