Fixed Q object merge edge case (MongoEngine/mongoengine#109)

This commit is contained in:
Ross Lawley
2012-09-03 11:33:30 +01:00
parent 52f85aab18
commit 576e198ece
3 changed files with 17 additions and 1 deletions

View File

@@ -218,7 +218,7 @@ class QNode(object):
def _combine(self, other, operation):
"""Combine this node with another node into a QCombination object.
"""
if other.empty:
if getattr(other, 'empty', True):
return self
if self.empty: