[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/gnorb b596ee7 157/449: Check for success when following
From: |
Stefan Monnier |
Subject: |
[elpa] externals/gnorb b596ee7 157/449: Check for success when following gnus links |
Date: |
Fri, 27 Nov 2020 23:15:29 -0500 (EST) |
branch: externals/gnorb
commit b596ee7f2a918cd42e88c094d79fcbf5ca9d3679
Author: Eric Abrahamsen <eric@ericabrahamsen.net>
Commit: Eric Abrahamsen <eric@ericabrahamsen.net>
Check for success when following gnus links
* lisp/gnorb-org.el (gnorb-org-setup-message): Previously,
`gnorb-org-handle-mail' would try to follow a link, but regardless of
whether the message was found or not, it would start a reply. That's
pretty much never correct, so check for that and bail if the link is
stale.
---
lisp/gnorb-org.el | 17 ++++++++++-------
1 file changed, 10 insertions(+), 7 deletions(-)
diff --git a/lisp/gnorb-org.el b/lisp/gnorb-org.el
index 8ca0c71..585140a 100644
--- a/lisp/gnorb-org.el
+++ b/lisp/gnorb-org.el
@@ -405,15 +405,18 @@ Org heading ids, associating the outgoing message with
those
headings."
(require 'gnorb-gnus)
(if (not messages)
- ;; either compose new message...
+ ;; Either compose new message...
(compose-mail (mapconcat 'identity mails ", "))
- ;; ...or follow link and start reply
+ ;; ...or follow link and start reply.
(condition-case err
- (progn
- (org-gnus-open (org-link-unescape (car messages)))
+ (let ((ret-val (org-gnus-open (org-link-unescape (car messages)))))
+ ;; We failed to open the link (probably), ret-val would be
+ ;; t otherwise
+ (when (stringp ret-val)
+ (error ret-val))
(call-interactively
'gnus-summary-wide-reply-with-original)
- ;; add MAILS to message To header
+ ;; Add MAILS to message To header.
(when mails
(message-goto-to)
(insert ", ")
@@ -421,10 +424,10 @@ headings."
(error (when (window-configuration-p gnorb-org-window-conf)
(set-window-configuration gnorb-org-window-conf))
(signal (car err) (cdr err)))))
- ;; return us after message is sent
+ ;; Return us after message is sent.
(add-to-list 'message-exit-actions
'gnorb-org-restore-after-send t)
- ;; set headers from MAIL_* properties (from, cc, and bcc)
+ ;; Set headers from MAIL_* properties (from, cc, and bcc).
(cl-flet ((sh (h)
(when (cdr h)
(funcall (intern (format "message-goto-%s" (car h))))
- [elpa] externals/gnorb 69980d3 143/449: Improvements to nnir-run-gnorb, (continued)
- [elpa] externals/gnorb 69980d3 143/449: Improvements to nnir-run-gnorb, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb ebce811 144/449: Also check for nnir when storing BBDB message links, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb 5101731 150/449: Improvements to TODOs made from outgoing messages, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb b841d17 146/449: Wishlist changes, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb 8958546 155/449: Backquote escape fail, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb 38df7d0 166/449: Ignore a notes.org file, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb 44f8d23 165/449: Begin shift to using the registry, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb c280ea4 160/449: Only add relevant sent messages in the registry, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb 4fc1075 172/449: Rename gnorb-org-window-conf to gnorb-window-conf, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb bb44a8c 174/449: Don't force id creation!, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb b596ee7 157/449: Check for success when following gnus links,
Stefan Monnier <=
- [elpa] externals/gnorb 43fbd55 176/449: New function for restoring window layout, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb fe7d814 179/449: Provide initialization of gnorb email tracking, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb b95f371 186/449: That's not how you use condition-case, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb 6653b6c 187/449: Fix gnorb-tracking-initialize, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb f0cfa7b 191/449: Improvements to gnorb-registry-make-entry, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb bdbc96f 195/449: Rename gnorb-gnus-sending-message-info, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb ca85930 197/449: First draft of trigger action reworking, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb 9e880eb 200/449: Improve Gnus summary hinting, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb 8a0d275 202/449: Docstring for gnorb-registry-org-id-search, Stefan Monnier, 2020/11/27
- [elpa] externals/gnorb 6293b22 208/449: Squash with the trigger action stuff, Stefan Monnier, 2020/11/27