X-Git-Url: http://git.ozlabs.org/?a=blobdiff_plain;f=apps%2Fpatchwork%2Fbin%2Fparsemail.py;h=d73343a9407fd5a0c36f2af0604f414189f3595c;hb=406d17e8df324c235172ed673ef65e998ca1f6a4;hp=2acceb5836a871835a42eff65f99360e078b6823;hpb=ab0062c77d1fd7d1ed583d3db6528a06bface822;p=patchwork diff --git a/apps/patchwork/bin/parsemail.py b/apps/patchwork/bin/parsemail.py index 2acceb5..d73343a 100755 --- a/apps/patchwork/bin/parsemail.py +++ b/apps/patchwork/bin/parsemail.py @@ -138,11 +138,12 @@ def find_content(project, mail): continue payload = part.get_payload(decode=True) + subtype = part.get_content_subtype() - if part.get_content_subtype() == 'x-patch': + if subtype in ['x-patch', 'x-diff']: patchbuf = payload - if part.get_content_subtype() == 'plain': + elif subtype == 'plain': if not patchbuf: (patchbuf, c) = parse_patch(payload) else: