Revert "Rewrite the empty function according to the new NotLoaded"

This reverts commit 22606d961f.
This commit is contained in:
Romain Bignon 2014-03-19 09:16:05 +01:00
commit 03ce941ccf

View file

@ -41,10 +41,8 @@ def empty(value):
:rtype: :class:`bool`
"""
if value is None:
return True
for cls in (NotLoadedType, NotAvailableType):
if type(value) is cls:
for cls in (None, NotLoaded, NotAvailable):
if value is cls:
return True
return False