From c1e5afed098133103c0d7c44db4da4a939aa6431 Mon Sep 17 00:00:00 2001 From: Anton-Latukha Date: Sun, 29 Sep 2019 03:10:25 +0300 Subject: [PATCH 2/2] org: org-get-priority: push same magic (* 1000 .. ) op outside of if * org (org-get-priority): Push the same magic (* 1000 ..) operation outside applying it to if overall. --- lisp/org.el | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/lisp/org.el b/lisp/org.el index 72408f49f..8aabce5f4 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -11679,10 +11679,11 @@ and by additional input from the age of a schedules or deadline entry." (save-match-data (if (functionp org-get-priority-function) (funcall org-get-priority-function) - (if (string-match org-priority-regexp s) - (* 1000 (- org-lowest-priority - (string-to-char (match-string 2 s)))) - (* 1000 (- org-lowest-priority org-default-priority)))))) + (* 1000 + (if (string-match org-priority-regexp s) + (- org-lowest-priority + (string-to-char (match-string 2 s))) + (- org-lowest-priority org-default-priority)))))) ;;;; Tags -- 2.23.0