* lisp/gnus/gnus-sum.el (gnus-summary-exit): Gnus message flags
must be set before expiration, not afterwards (bug#21071).
(gnus-score-adaptive))
(when gnus-use-scoring
(gnus-score-save)))
- (gnus-run-hooks 'gnus-summary-prepare-exit-hook)
(when gnus-use-cache
(gnus-cache-possibly-remove-articles)
(gnus-cache-save-buffers))
(unless quit-config
(gnus-run-hooks 'gnus-exit-group-hook)
(gnus-summary-update-info))
+ (gnus-run-hooks 'gnus-summary-prepare-exit-hook)
(gnus-close-group group)
;; Make sure where we were, and go to next newsgroup.
(when (gnus-buffer-live-p gnus-group-buffer)