mirror of
https://git.notmuchmail.org/git/notmuch
synced 2024-11-24 11:58:10 +01:00
cli/show: pass the siglist directly to the sigstatus sprinter
This makes it easier to reuse format_part_sigstatus_sprinter() when we have other places that we want to display a signature status.
This commit is contained in:
parent
22ec4a36e6
commit
325a924227
1 changed files with 2 additions and 4 deletions
|
@ -429,13 +429,11 @@ format_signature_errors (sprinter_t *sp, GMimeSignature *signature)
|
||||||
|
|
||||||
/* Signature status sprinter (GMime 2.6) */
|
/* Signature status sprinter (GMime 2.6) */
|
||||||
static void
|
static void
|
||||||
format_part_sigstatus_sprinter (sprinter_t *sp, mime_node_t *node)
|
format_part_sigstatus_sprinter (sprinter_t *sp, GMimeSignatureList *siglist)
|
||||||
{
|
{
|
||||||
/* Any changes to the JSON or S-Expression format should be
|
/* Any changes to the JSON or S-Expression format should be
|
||||||
* reflected in the file devel/schemata. */
|
* reflected in the file devel/schemata. */
|
||||||
|
|
||||||
GMimeSignatureList *siglist = node->sig_list;
|
|
||||||
|
|
||||||
sp->begin_list (sp);
|
sp->begin_list (sp);
|
||||||
|
|
||||||
if (!siglist) {
|
if (!siglist) {
|
||||||
|
@ -684,7 +682,7 @@ format_part_sprinter (const void *ctx, sprinter_t *sp, mime_node_t *node,
|
||||||
|
|
||||||
if (node->verify_attempted) {
|
if (node->verify_attempted) {
|
||||||
sp->map_key (sp, "sigstatus");
|
sp->map_key (sp, "sigstatus");
|
||||||
format_part_sigstatus_sprinter (sp, node);
|
format_part_sigstatus_sprinter (sp, node->sig_list);
|
||||||
}
|
}
|
||||||
|
|
||||||
sp->map_key (sp, "content-type");
|
sp->map_key (sp, "content-type");
|
||||||
|
|
Loading…
Reference in a new issue