From 1f8a041e25c280eeac37d516bc77eb3b8f0d40f9 Mon Sep 17 00:00:00 2001 From: Naoya Yamashita Date: Fri, 5 Jul 2024 06:55:51 +0900 Subject: [PATCH] call cider-docstring--format after checking argument --- cider-eldoc.el | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/cider-eldoc.el b/cider-eldoc.el index 4c094b06c..9a3266272 100644 --- a/cider-eldoc.el +++ b/cider-eldoc.el @@ -218,9 +218,10 @@ information." (symbol (lax-plist-get eldoc-info "symbol")) (docstring (or (cider--render-docstring-first-sentence eldoc-info) (cider--render-docstring eldoc-info) - (cider-docstring--trim - (cider-docstring--format - (lax-plist-get eldoc-info "docstring"))))) + (when (lax-plist-get eldoc-info "docstring") + (cider-docstring--trim + (cider-docstring--format + (lax-plist-get eldoc-info "docstring")))))) ;; if it's a single class (and not multiple class candidates), that's it (maybe-class (car (lax-plist-get eldoc-info "class"))) (formatted-var (or (when maybe-class