;;;###autoload
(defun gnus-bbdb/update-record (&optional offer-to-create)
- "returns the record corresponding to the current GNUS message, creating
-or modifying it as necessary. A record will be created if
+ "returns the record corresponding to the current GNUS message, creating
+or modifying it as necessary. A record will be created if
bbdb/news-auto-create-p is non-nil, or if OFFER-TO-CREATE is true and
the user confirms the creation."
(if bbdb-use-pop-up
(gnus-bbdb/extract-address-components
(gnus-bbdb/decode-field-body to 'To))))))
(when from
- (bbdb-annotate-message-sender from t
- (or (bbdb-invoke-hook-for-value
- bbdb/news-auto-create-p)
- offer-to-create)
- offer-to-create)))))
+ (save-excursion
+ (bbdb-annotate-message-sender from t
+ (or (bbdb-invoke-hook-for-value
+ bbdb/news-auto-create-p)
+ offer-to-create)
+ offer-to-create))))))
;;;###autoload
(defun gnus-bbdb/annotate-sender (string &optional replace)
(when (boundp 'bbdb-extract-field-value-function-list)
(add-to-list 'bbdb-extract-field-value-function-list
'gnus-bbdb/extract-field-value-init))
- (add-hook 'gnus-article-display-hook 'gnus-bbdb/update-record)
+ (add-hook 'gnus-article-prepare-hook 'gnus-bbdb/update-record)
(add-hook 'gnus-save-newsrc-hook 'bbdb-offer-save)
(define-key gnus-summary-mode-map ":" 'gnus-bbdb/show-sender)
(define-key gnus-summary-mode-map ";" 'gnus-bbdb/edit-notes)