Small fix for Python 2.5

This commit is contained in:
Viktor Kerkez 2010-10-23 22:33:03 +02:00
parent e868f37c60
commit f0c5dd1bce
2 changed files with 4 additions and 1 deletions

4
.gitignore vendored
View File

@ -6,4 +6,6 @@ docs/_build
build/
dist/
mongoengine.egg-info/
env/
env/
.project
.pydevproject

View File

@ -491,6 +491,7 @@ class BaseDocument(object):
if sys.version_info < (2, 5):
# Prior to Python 2.5, Exception was an old-style class
import types
def subclass_exception(name, parents, unused):
return types.ClassType(name, parents, {})
else: