emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] 1.2 13b8c61 040/101: Per #74: Don't error if server replies with


From: Christian Johansson
Subject: [elpa] 1.2 13b8c61 040/101: Per #74: Don't error if server replies with empty hover message
Date: Thu, 29 Apr 2021 15:08:57 -0400 (EDT)

tag: 1.2
commit 13b8c61d67486400ffe987cfd84d22027ff4c923
Author: João Távora <joaotavora@gmail.com>
Commit: João Távora <joaotavora@gmail.com>

    Per #74: Don't error if server replies with empty hover message
    
    * eglot.el (eglot-eldoc-function): Check non-nil contents.
---
 eglot.el | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/eglot.el b/eglot.el
index 6f36761..3fd98c7 100644
--- a/eglot.el
+++ b/eglot.el
@@ -1512,7 +1512,9 @@ If SKIP-SIGNATURE, don't try to send 
textDocument/signatureHelp."
          :success-fn (jsonrpc-lambda (&key contents range)
                        (unless sig-showing
                          (when-buffer-window
-                          (when-let (info (eglot--hover-info contents range))
+                          (when-let (info (and contents
+                                               (eglot--hover-info contents
+                                                                  range)))
                             (eldoc-message info)))))
          :deferred :textDocument/hover))
       (when (eglot--server-capable :documentHighlightProvider)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]