From: ueno Date: Mon, 4 Apr 2005 07:32:52 +0000 (+0000) Subject: * riece-misc.el (riece-get-channels-on-server): New function. X-Git-Tag: channel-coding-mergepoint~22 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=4e21a7cb0007470acf57c5bf99e41d1f25272211;p=elisp%2Friece.git * riece-misc.el (riece-get-channels-on-server): New function. (riece-get-users-on-server): Don't use riece-user-p. (riece-get-identities-on-server): Call riece-get-channels-on-server and riece-get-users-on-server. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index da3f1f5..cdccca6 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,10 @@ 2005-04-04 Daiki Ueno + * riece-misc.el (riece-get-channels-on-server): New function. + (riece-get-users-on-server): Don't use riece-user-p. + (riece-get-identities-on-server): Call + riece-get-channels-on-server and riece-get-users-on-server. + * riece-identity.el (riece-completing-read-identity): Don't signal an error when input string does not match riece-channel-regexp nor riece-user-regexp. diff --git a/lisp/riece-misc.el b/lisp/riece-misc.el index bc1e2c9..eb0de20 100644 --- a/lisp/riece-misc.el +++ b/lisp/riece-misc.el @@ -214,12 +214,17 @@ user-at-host)) (defun riece-get-users-on-server (server-name) - (delq nil (mapcar (lambda (identity) - (if (riece-user-p (riece-identity-prefix identity)) - identity)) - (riece-get-identities-on-server server-name)))) + (riece-with-server-buffer server-name + (let (identities) + (mapatoms + (lambda (user) + (setq identities + (cons (riece-make-identity (symbol-name user) server-name) + identities))) + riece-user-obarray) + identities))) -(defun riece-get-identities-on-server (server-name) +(defun riece-get-channels-on-server (server-name) (riece-with-server-buffer server-name (let (identities) (mapatoms @@ -228,14 +233,12 @@ (cons (riece-make-identity (symbol-name channel) server-name) identities))) riece-channel-obarray) - (mapatoms - (lambda (user) - (setq identities - (cons (riece-make-identity (symbol-name user) server-name) - identities))) - riece-user-obarray) identities))) +(defun riece-get-identities-on-server (server-name) + (nconc (riece-get-channels-on-server server-name) + (riece-get-users-on-server server-name))) + (defun riece-check-channel-commands-are-usable (&optional channel) (unless riece-current-channel (error (substitute-command-keys