From: Lars Ingebrigtsen Date: Tue, 18 Aug 2020 09:23:47 +0000 (+0200) Subject: Remove some compat code from erc-track.el X-Git-Tag: emacs-28.0.90~6572 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=128b04fca08f791a4eba64e8c1fe3429df7e822f;p=emacs.git Remove some compat code from erc-track.el * lisp/erc/erc-track.el (erc-track-remove-from-mode-line) (erc-track-add-to-mode-line): Remove check for mode-line-modes, which is always bound. --- diff --git a/lisp/erc/erc-track.el b/lisp/erc/erc-track.el index 820b6d9359b..3398c8b9d0c 100644 --- a/lisp/erc/erc-track.el +++ b/lisp/erc/erc-track.el @@ -328,9 +328,8 @@ important." (defun erc-track-remove-from-mode-line () "Remove `erc-track-modified-channels' from the mode-line." - (when (boundp 'mode-line-modes) - (setq mode-line-modes - (remove '(t erc-modified-channels-object) mode-line-modes))) + (setq mode-line-modes + (remove '(t erc-modified-channels-object) mode-line-modes)) (when (consp global-mode-string) (setq global-mode-string (delq 'erc-modified-channels-object global-mode-string)))) @@ -340,12 +339,10 @@ important." See `erc-track-position-in-mode-line' for possible values." ;; CVS Emacs has a new format string, and global-mode-string ;; is very far to the right. - (cond ((and (eq position 'before-modes) - (boundp 'mode-line-modes)) + (cond ((eq position 'before-modes) (add-to-list 'mode-line-modes '(t erc-modified-channels-object))) - ((and (eq position 'after-modes) - (boundp 'mode-line-modes)) + ((eq position 'after-modes) (add-to-list 'mode-line-modes '(t erc-modified-channels-object) t)) ((eq position t)