forked from mirrors/org-mode
org-gnus: Check nnimap-group-overview-filename
* lisp/org-gnus.el (org-gnus-nnimap-cached-article-number): Check that nnimap-group-overview-filename, which was removed from Emacs in 2010, is defined before calling.
This commit is contained in:
parent
1c9bb0dba8
commit
0e0963acbf
|
@ -79,15 +79,17 @@ this variable to t."
|
|||
|
||||
;; Implementation
|
||||
|
||||
;; FIXME: nnimap-group-overview-filename was removed from Gnus in
|
||||
;; September 2010. Perhaps remove this function?
|
||||
(defun org-gnus-nnimap-cached-article-number (group server message-id)
|
||||
"Return cached article number (uid) of message in GROUP on SERVER.
|
||||
MESSAGE-ID is the message-id header field that identifies the
|
||||
message. If the uid is not cached, return nil."
|
||||
(with-temp-buffer
|
||||
(let ((nov (nnimap-group-overview-filename group server)))
|
||||
(when (file-exists-p nov)
|
||||
(let ((nov (and (fboundp 'nnimap-group-overview-filename)
|
||||
;; nnimap-group-overview-filename was removed from
|
||||
;; Gnus in September 2010, and therefore should
|
||||
;; only be present in Emacs 23.1.
|
||||
(nnimap-group-overview-filename group server))))
|
||||
(when (and nov (file-exists-p nov))
|
||||
(mm-insert-file-contents nov)
|
||||
(set-buffer-modified-p nil)
|
||||
(goto-char (point-min))
|
||||
|
|
Loading…
Reference in New Issue