From fc460dc12b88316af47d8484acc3f1628325cd5d Mon Sep 17 00:00:00 2001 From: "neiljp (Neil Pilgrim)" Date: Fri, 22 Dec 2017 22:17:13 -0800 Subject: [PATCH] mypy: Rewrite trac integration for clarity & to pass strict-optional. --- zulip/integrations/trac/zulip_trac.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/zulip/integrations/trac/zulip_trac.py b/zulip/integrations/trac/zulip_trac.py index bbfc317..b661788 100644 --- a/zulip/integrations/trac/zulip_trac.py +++ b/zulip/integrations/trac/zulip_trac.py @@ -115,9 +115,9 @@ class ZulipPlugin(Component): else: content += ":\n\n" field_changes = [] - for key in old_values.keys(): + for key, value in old_values.items(): if key == "description": - content += '- Changed %s from %s\n\nto %s' % (key, markdown_block(old_values.get(key)), + content += '- Changed %s from %s\n\nto %s' % (key, markdown_block(value), markdown_block(ticket.values.get(key))) elif old_values.get(key) == "": field_changes.append('%s: => **%s**' % (key, ticket.values.get(key)))