mirror of
https://git.notmuchmail.org/git/notmuch
synced 2024-11-22 02:48:08 +01:00
show: include Reply-To header in json output
Output the Reply-To header field if present in a message. I want to be able to see what the sender intended in my mail client, before hitting the reply key. Only json output is changed, like the recently added Bcc field.
This commit is contained in:
parent
439fe710eb
commit
7d3c06dcbe
1 changed files with 7 additions and 0 deletions
|
@ -210,6 +210,7 @@ format_headers_json (sprinter_t *sp, GMimeMessage *message,
|
||||||
{
|
{
|
||||||
InternetAddressList *recipients;
|
InternetAddressList *recipients;
|
||||||
const char *recipients_string;
|
const char *recipients_string;
|
||||||
|
const char *reply_to_string;
|
||||||
|
|
||||||
sp->begin_map (sp);
|
sp->begin_map (sp);
|
||||||
|
|
||||||
|
@ -240,6 +241,12 @@ format_headers_json (sprinter_t *sp, GMimeMessage *message,
|
||||||
sp->string (sp, recipients_string);
|
sp->string (sp, recipients_string);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
reply_to_string = g_mime_message_get_reply_to (message);
|
||||||
|
if (reply_to_string) {
|
||||||
|
sp->map_key (sp, "Reply-To");
|
||||||
|
sp->string (sp, reply_to_string);
|
||||||
|
}
|
||||||
|
|
||||||
if (reply) {
|
if (reply) {
|
||||||
sp->map_key (sp, "In-reply-to");
|
sp->map_key (sp, "In-reply-to");
|
||||||
sp->string (sp, g_mime_object_get_header (GMIME_OBJECT (message), "In-reply-to"));
|
sp->string (sp, g_mime_object_get_header (GMIME_OBJECT (message), "In-reply-to"));
|
||||||
|
|
Loading…
Reference in a new issue