From ead28f59e2902c5f31606be8f733e3c9f62ff185 Mon Sep 17 00:00:00 2001 From: Eliot Horowitz Date: Thu, 21 Jan 2010 23:26:46 -0500 Subject: [PATCH] fix $unset combined with other modifier bug --- db/update.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/db/update.cpp b/db/update.cpp index be195a762dd..26f79b41495 100644 --- a/db/update.cpp +++ b/db/update.cpp @@ -235,7 +235,8 @@ namespace mongo { BSONElement e = obj.getFieldDotted(m.fieldName); if ( e.eoo() ) { - inPlacePossible = (m.op == Mod::UNSET); + if ( inPlacePossible ) + inPlacePossible = (m.op == Mod::UNSET); } else { switch( m.op ) {