From 19563ceb4e58024f77a2b988c860131cc65ae4f3 Mon Sep 17 00:00:00 2001 From: Takafumi Arakaki Date: Wed, 25 Jul 2012 18:55:55 +0200 Subject: [PATCH] Refactor ein:kernel-construct-help-string --- lisp/ein-kernel.el | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/lisp/ein-kernel.el b/lisp/ein-kernel.el index 1d69318..2bd6257 100644 --- a/lisp/ein-kernel.el +++ b/lisp/ein-kernel.el @@ -509,14 +509,15 @@ Used in `ein:cell-finish-tooltip', etc." (ein:kernel-construct-defstring content) (ansi-color-apply it) (ein:string-fill-paragraph it))) - (docstring (or (plist-get content :call_docstring) - (plist-get content :init_docstring) - (plist-get content :docstring) - ;; "" - )) - (help - (ein:aif (ein:filter 'identity (list defstring docstring)) - (ansi-color-apply (ein:join-str "\n" it))))) + (docstring (ein:aand + (or (plist-get content :call_docstring) + (plist-get content :init_docstring) + (plist-get content :docstring) + ;; "" + ) + (ansi-color-apply it))) + (help (ein:join-str + "\n" (ein:filter 'identity (list defstring docstring))))) (ein:log 'debug "EIN:KERNEL-CONSTRUCT-HELP-STRING") (ein:log 'debug "help %s" help) help))