Indexing on ListFields now works properly

This commit is contained in:
Harry Marr
2010-01-16 15:35:01 +00:00
parent f01add9ef5
commit 3357b55fbf
4 changed files with 44 additions and 12 deletions

View File

@@ -142,6 +142,9 @@ class ListField(BaseField):
of the field to be used as a list in the database.
"""
# ListFields cannot be indexed with _types - MongoDB doesn't support this
_index_with_types = False
def __init__(self, field, **kwargs):
if not isinstance(field, BaseField):
raise ValidationError('Argument to ListField constructor must be '