Use types.StringTypes instead of explicit (str, unicode) list

This commit is contained in:
Michael W. Hudson 2002-05-20 17:29:46 +00:00
parent 7b7ba54033
commit 755f75eef8

View File

@ -267,7 +267,7 @@ def getdoc(object):
doc = object.__doc__
except AttributeError:
return None
if not isinstance(doc, (str, unicode)):
if not isinstance(doc, types.StringTypes):
return None
try:
lines = string.split(string.expandtabs(doc), '\n')