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

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

[nongnu] elpa/with-editor 791f985 042/140: with-editor-locate-emacsclien


From: Jonas Bernoulli
Subject: [nongnu] elpa/with-editor 791f985 042/140: with-editor-locate-emacsclient: fix previous commit
Date: Fri, 6 Aug 2021 12:51:16 -0400 (EDT)

branch: elpa/with-editor
commit 791f985f63abe7f10de3fbd6fd49f9efac05a285
Author: Jonas Bernoulli <jonas@bernoul.li>
Commit: Jonas Bernoulli <jonas@bernoul.li>

    with-editor-locate-emacsclient: fix previous commit
    
    If `*-1' fails, then we have to return nil.  To make it clear
    that this is what happens, show the return value (nil) before
    the sexp-wise confusing multi-line warning text.
    
    Also remove the unnecessary `format'.
---
 with-editor.el | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/with-editor.el b/with-editor.el
index 54b43b9..c522bed 100644
--- a/with-editor.el
+++ b/with-editor.el
@@ -108,13 +108,12 @@
 (defun with-editor-locate-emacsclient ()
   "Search for a suitable Emacsclient executable."
   (or (with-editor-locate-emacsclient-1 (with-editor-emacsclient-path) 3)
-      (display-warning 'with-editor (format "\
+      (prog1 nil (display-warning 'with-editor "\
 Cannot determine a suitable Emacsclient
 
 Determining an Emacsclient executable suitable for the
 current Emacs instance failed.  For more information
-please see https://github.com/magit/magit/wiki/Emacsclient.";))
-      nil))
+please see https://github.com/magit/magit/wiki/Emacsclient.";))))
 
 (defun with-editor-locate-emacsclient-1 (path depth)
   (let* ((version-lst (-take depth (split-string emacs-version "\\.")))



reply via email to

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