diff options
| author | Barry Warsaw | 2011-04-27 21:48:03 -0400 |
|---|---|---|
| committer | Barry Warsaw | 2011-04-27 21:48:03 -0400 |
| commit | 4185e010820df965fdded840cd088ac7d0f49b53 (patch) | |
| tree | 2cb4efeb43e2a297202ae1ac2747c0773c0b59ac /src/mailman/bouncers/netscape.py | |
| parent | 50823ea9d544114603b3f5d814914908b27749d6 (diff) | |
| parent | c2b79a2461501c6a83f02a11dba4d847f34e1b6e (diff) | |
| download | mailman-4185e010820df965fdded840cd088ac7d0f49b53.tar.gz mailman-4185e010820df965fdded840cd088ac7d0f49b53.tar.zst mailman-4185e010820df965fdded840cd088ac7d0f49b53.zip | |
Restore the bounce detectors tests which previously got accidentally removed
in a merge mistake. Also, make the tests pass <wink>.
Also, refactor find_components() into a separate function scan_module() so
that we can just extract the components from a single module.
Diffstat (limited to 'src/mailman/bouncers/netscape.py')
| -rw-r--r-- | src/mailman/bouncers/netscape.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mailman/bouncers/netscape.py b/src/mailman/bouncers/netscape.py index 77df3f224..0f09cdfa9 100644 --- a/src/mailman/bouncers/netscape.py +++ b/src/mailman/bouncers/netscape.py @@ -75,7 +75,7 @@ class Netscape: # and some show # multipart/mixed; if not msg.is_multipart(): - return None + return set() # We're looking for a text/plain subpart occuring before a # message/delivery-status subpart. plainmsg = None @@ -86,7 +86,7 @@ class Netscape: plainmsg = subpart break if not plainmsg: - return None + return set() # Total guesswork, based on captured examples... body = StringIO(plainmsg.get_payload()) addresses = set() @@ -100,4 +100,4 @@ class Netscape: mo = acre.search(line) if mo and not mo.group('reply'): addresses.add(mo.group('addr')) - return list(addresses) + return addresses |
