From eafec1989a5f22108e7edbe6fb64426518d2f55d Mon Sep 17 00:00:00 2001 From: syl20bnr Date: Mon, 2 Nov 2015 23:02:01 -0500 Subject: [PATCH] spell-checking: replace lambda by named function --- layers/spell-checking/packages.el | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/layers/spell-checking/packages.el b/layers/spell-checking/packages.el index 4774e1355..2039ef63e 100644 --- a/layers/spell-checking/packages.el +++ b/layers/spell-checking/packages.el @@ -27,13 +27,13 @@ ;; Select the buffer local dictionary if it was set, otherwise ;; auto-dictionary will replace it with a guessed one at each activation. ;; https://github.com/nschum/auto-dictionary-mode/issues/5 + (defun spacemacs//adict-set-local-dictionary () + "Set the local dictionary if not nil." + (when (and (fboundp 'adict-change-dictionary) + ispell-local-dictionary) + (adict-change-dictionary ispell-local-dictionary))) (add-hook 'auto-dictionary-mode-hook - (lambda () - (when (and - (fboundp 'adict-change-dictionary) - ispell-local-dictionary) - (adict-change-dictionary ispell-local-dictionary))) 'append) - ))) + 'spacemacs//adict-set-local-dictionary 'append)))) (defun spell-checking/init-flyspell () (use-package flyspell