]> git.ipfire.org Git - thirdparty/patchwork.git/commit
parser: Correct empty email value check
authorStephen Finucane <stephen.finucane@intel.com>
Mon, 18 Apr 2016 10:21:09 +0000 (11:21 +0100)
committerStephen Finucane <stephenfinucane@hotmail.com>
Fri, 2 Sep 2016 19:04:14 +0000 (20:04 +0100)
commitdf6dada6bed15216950fb3e8ccf2c1f30c688038
treec996441191fcb052330c0ca450eb4a33c3e9ca71
parent144e7500dad449eb1eb33741a16324cd63e1a4f3
parser: Correct empty email value check

The check for empty emails in 'find_author' checked for None, but it
was not possible to ever return None unless the 'From:' header was
missing altogether. Seeing as, per RFC822 and its revisions, this is
not possible, check for the empty string instead.

Signed-off-by: Stephen Finucane <stephen.finucane@intel.com>
Reviewed-by: Andy Doan <andy.doan@linaro.org>
patchwork/parser.py
patchwork/tests/test_parser.py