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

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

[elpa] externals/luwak 544187e3e7 26/28: fixed a bug when no title could


From: ELPA Syncer
Subject: [elpa] externals/luwak 544187e3e7 26/28: fixed a bug when no title could be guessed.
Date: Tue, 25 Oct 2022 15:57:55 -0400 (EDT)

branch: externals/luwak
commit 544187e3e7ee057b97e2048f71f4e19396884b50
Author: Yuchen Pei <hi@ypei.me>
Commit: Yuchen Pei <hi@ypei.me>

    fixed a bug when no title could be guessed.
---
 luwak.el | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/luwak.el b/luwak.el
index b0f7440e47..08eb7931ff 100644
--- a/luwak.el
+++ b/luwak.el
@@ -115,9 +115,9 @@ When non-nill, swap the tor-switch in prefix-arg effect."
 (defun luwak-guess-title ()
   (save-excursion
     (goto-char (point-min))
-    (re-search-forward "^[^[:space:]]" nil t)
-    (buffer-substring-no-properties (1- (point))
-                                    (progn (end-of-line 1) (point)))))
+    (when (re-search-forward "^[^[:space:]]" nil t)
+      (buffer-substring-no-properties (1- (point))
+                                      (progn (end-of-line 1) (point))))))
 
 (when (require 'org nil t)
   (defun luwak-org-store-link ()



reply via email to

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