Skip to content

Commit 6ea2cc3

Browse files
alexander-yakushevbbatsov
authored andcommitted
[eldoc] Don't error on missing docstring
1 parent e330674 commit 6ea2cc3

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

cider-docstring.el

+2-1
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,8 @@ that it usually has two spaces before each line used for indentation
157157
\(see https://guide.clojure.style/#docstring-indentation). While displaying
158158
the docstring to the user, we usually want to control indentation and
159159
other aspects of the presentation, so we format it before displaying."
160-
(replace-regexp-in-string "\n " "\n" string))
160+
(when string
161+
(replace-regexp-in-string "\n " "\n" string)))
161162

162163
(provide 'cider-docstring)
163164
;;; cider-docstring.el ends here

0 commit comments

Comments
 (0)