diff detectors/emailauditor.py @ 5381:0942fe89e82e

Python 3 preparation: change "x.has_key(y)" to "y in x". (Also likewise "not in" where appropriate.) Tool-generated patch.
author Joseph Myers <jsm@polyomino.org.uk>
date Tue, 24 Jul 2018 22:08:17 +0000
parents 6b32e9dac625
children
line wrap: on
line diff
--- a/detectors/emailauditor.py	Tue Jul 24 21:43:32 2018 +0000
+++ b/detectors/emailauditor.py	Tue Jul 24 22:08:17 2018 +0000
@@ -29,7 +29,7 @@
 
     So... we do that. :)'''
     if newvalues.get('type', '').lower() == "message/rfc822":
-        if not newvalues.has_key('name'):
+        if 'name' not in newvalues:
             newvalues['name'] = 'email.mht'
             return
         name = newvalues['name']

Roundup Issue Tracker: http://roundup-tracker.org/