Function: erc-sort-channel-users-alphabetically
erc-sort-channel-users-alphabetically is a byte-compiled function
defined in erc.el.gz.
Signature
(erc-sort-channel-users-alphabetically LIST)
Documentation
Sort LIST so that users' nicknames are in alphabetical order.
LIST must be of the form (USER . CHANNEL-DATA).
See also: erc-get-channel-user-list.
Source Code
;; Defined in /usr/src/emacs/lisp/erc/erc.el.gz
(defun erc-sort-channel-users-alphabetically (list)
"Sort LIST so that users' nicknames are in alphabetical order.
LIST must be of the form (USER . CHANNEL-DATA).
See also: `erc-get-channel-user-list'."
(sort list
(lambda (x y)
(when (and (cdr x) (cdr y))
(let ((nickx (downcase (erc-server-user-nickname (car x))))
(nicky (downcase (erc-server-user-nickname (car y)))))
(and nickx
(or (not nicky)
(string-lessp nickx nicky))))))))