;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with this program; if not, you can either send email to this
-;; program's maintainer or write to: The Free Software Foundation,
-;; Inc.; 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+;; Boston, MA 02110-1301, USA.
;;; Commentary:
(wl-draft-write-sendlog 'ok 'mixi nil (list recipients) id))))
(defun mixi-wl-setup-draft-buffer ()
- (when (string-match mixi-to-regexp (mixi-wl-get-recipients-from-buffer))
- (make-local-variable 'wl-draft-send-confirm-with-preview)
- (setq wl-draft-send-confirm-with-preview nil)
- (make-local-variable 'wl-draft-send-mail-function)
- (setq wl-draft-send-mail-function 'wl-draft-send-mail-with-mixi)))
+ (let ((recipients (mixi-wl-get-recipients-from-buffer)))
+ (when (and recipients
+ (string-match mixi-to-regexp recipients))
+ (make-local-variable 'wl-draft-send-confirm-with-preview)
+ (setq wl-draft-send-confirm-with-preview nil)
+ (make-local-variable 'wl-draft-send-mail-function)
+ (setq wl-draft-send-mail-function 'wl-draft-send-mail-with-mixi))))
(defun mixi-wl-setup ()
(add-hook 'wl-draft-send-hook 'mixi-wl-setup-draft-buffer))