ObjectIdField.to_python returns pymongo.objectid.ObjectId
This commit is contained in:
parent
1818cf7114
commit
1cdeb8130d
@ -69,7 +69,8 @@ class ObjectIdField(BaseField):
|
|||||||
"""
|
"""
|
||||||
|
|
||||||
def to_python(self, value):
|
def to_python(self, value):
|
||||||
return unicode(value)
|
return value
|
||||||
|
# return unicode(value)
|
||||||
|
|
||||||
def to_mongo(self, value):
|
def to_mongo(self, value):
|
||||||
if not isinstance(value, pymongo.objectid.ObjectId):
|
if not isinstance(value, pymongo.objectid.ObjectId):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user