From 6bd3d8af5431542f352f084b6366e88b98b019a1 Mon Sep 17 00:00:00 2001 From: David Edmondson Date: Mon, 30 Jan 2012 10:16:01 +0000 Subject: emacs: Prefer '[No Subject]' to blank subjects. --- emacs/notmuch-lib.el | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'emacs/notmuch-lib.el') diff --git a/emacs/notmuch-lib.el b/emacs/notmuch-lib.el index c906ca76..d315f765 100644 --- a/emacs/notmuch-lib.el +++ b/emacs/notmuch-lib.el @@ -133,6 +133,15 @@ the user hasn't set this variable with the old or new value." (interactive) (kill-buffer (current-buffer))) +(defun notmuch-prettify-subject (subject) + ;; This function is used by `notmuch-search-process-filter' which + ;; requires that we not disrupt its' matching state. + (save-match-data + (if (and subject + (string-match "^[ \t]*$" subject)) + "[No Subject]" + subject))) + ;; (defun notmuch-common-do-stash (text) -- cgit v1.2.3