From: dickmao Date: Wed, 23 Jun 2021 12:50:05 +0000 (+0200) Subject: Clean up code in `message-replace-header' X-Git-Tag: emacs-28.0.90~2053 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=d87b67a9e24ecc6c777fad0e3e6b71a7b68ab0df;p=emacs.git Clean up code in `message-replace-header' * lisp/gnus/message.el (message-replace-header): Elide redundancy (bug#49180). --- 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