From 092ac7e977ddb6a2bdfc3aa280caab1408924715 Mon Sep 17 00:00:00 2001 From: ueno Date: Fri, 26 Aug 2005 06:40:24 +0000 Subject: [PATCH] Throw an error if add-on is not insinuated when enabling/disabling. --- lisp/riece-addon.el | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lisp/riece-addon.el b/lisp/riece-addon.el index a46fcb3..c1cdb78 100644 --- a/lisp/riece-addon.el +++ b/lisp/riece-addon.el @@ -234,6 +234,8 @@ (message "Add-on %S is uninstalled" addon))))) (defun riece-enable-addon (addon &optional verbose) + (unless (get addon 'riece-addon-insinuated) + (error "Add-on %S is not insinuated" addon)) (let ((enabled (intern-soft (concat (symbol-name addon) "-enabled")))) (if (null enabled) (if verbose @@ -246,6 +248,8 @@ (message "Add-on %S enabled" addon)))))) (defun riece-disable-addon (addon &optional verbose) + (unless (get addon 'riece-addon-insinuated) + (error "Add-on %S is not insinuated" addon)) (let ((enabled (intern-soft (concat (symbol-name addon) "-enabled")))) (if (null enabled) (if verbose -- 1.7.10.4