Cleaned up _to_{python,mongo} + _validate mess
This commit is contained in:
parent
d4fc5c9260
commit
f2d4ffa091
4 changed files with 38 additions and 40 deletions
|
|
@ -18,7 +18,7 @@ class Document(BaseDocument):
|
|||
"""Save the document to the database. If the document already exists,
|
||||
it will be updated, otherwise it will be created.
|
||||
"""
|
||||
_id = self.objects._collection.save(self._to_mongo())
|
||||
_id = self.objects._collection.save(self.to_mongo())
|
||||
self._id = _id
|
||||
|
||||
@classmethod
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue