From d87b67a9e24ecc6c777fad0e3e6b71a7b68ab0df Mon Sep 17 00:00:00 2001 From: dickmao Date: Wed, 23 Jun 2021 14:50:05 +0200 Subject: [PATCH] Clean up code in `message-replace-header' * lisp/gnus/message.el (message-replace-header): Elide redundancy (bug#49180). --- lisp/gnus/message.el | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/lisp/gnus/message.el b/lisp/gnus/message.el index 69e2c5cbbc1..a9be2d6b347 100644 --- a/lisp/gnus/message.el +++ b/lisp/gnus/message.el @@ -8730,12 +8730,10 @@ headers. If FORCE, insert new field even if NEW-VALUE is empty." (message-narrow-to-headers) (message-remove-header header)) (when (or force (> (length new-value) 0)) - (if after - (apply #'message-position-on-field header - (if (listp after) - after - (list after))) - (message-position-on-field header)) + (apply #'message-position-on-field header + (if (listp after) + after + (list after))) (insert new-value)))) (make-obsolete-variable -- 2.39.2