Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

ReferenceField(required=False) doesn't allow to be None #57

gaussgss opened this Issue Jul 15, 2010 · 2 comments


None yet
2 participants

test piece:

class Doc1(Document):
  title = StringField()

class Doc2(Document):
  ref = ReferenceField(Doc1, required = False)

>>> a = Doc1(title = 'abl')
>>> a.save()
>>> b = Doc2(ref = a)
>>> b.save()
>>> b.ref = None
>>> b.save()

flosch commented Jul 25, 2010

Seems to be already fixed, your example works. Please close this issue.

Yes, it works now, thanks.

@rozza rozza added a commit that referenced this issue Aug 3, 2012

@rozza rozza Merge pull request #57 from filipd/patch-1
Added reference to the official repository in the README

This issue was closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment