jschrewe / django-mongoadmin

Integrates mongodb into django's admin
http://www.schafproductions.com/projects/mongo-admin/
BSD 3-Clause "New" or "Revised" License
112 stars 38 forks source link

patch to fix saving error related to missing new_objects attribute #36

Open replabrobin opened 8 years ago

replabrobin commented 8 years ago

Hi, following patch fixes an error in Django 1.8.8 where saving any change causes a missing attribute new_objects traceback.

diff --git a/mongodbforms/documents.py b/mongodbforms/documents.py index 0a432a8..0397c2d 100644 --- a/mongodbforms/documents.py +++ b/mongodbforms/documents.py @@ -703,9 +703,16 @@ class BaseDocumentFormSet(BaseFormSet): Saves model instances for every form, adding and changing instances as necessary, and returns the list of instances. """ + saved = []

replabrobin commented 8 years ago

Sorry that patch is mongodbforms. I'll put it there as well.