]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
is_multipart(): Use isinstance() instead of type equality.
authorBarry Warsaw <barry@python.org>
Sat, 28 Sep 2002 20:41:39 +0000 (20:41 +0000)
committerBarry Warsaw <barry@python.org>
Sat, 28 Sep 2002 20:41:39 +0000 (20:41 +0000)
Lib/email/Message.py

index db4b9a2872dbcdb6c0606ab911f41d069a3871a9..49ab2660902291e323cc64198e167af0d80f1b88 100644 (file)
@@ -107,7 +107,7 @@ class Message:
 
     def is_multipart(self):
         """Return True if the message consists of multiple parts."""
-        if type(self._payload) is ListType:
+        if isinstance(self._payload, ListType):
             return True
         return False