summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/mongo/db/exec/multi_plan.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mongo/db/exec/multi_plan.cpp b/src/mongo/db/exec/multi_plan.cpp
index cff149dd182..b95284d3b87 100644
--- a/src/mongo/db/exec/multi_plan.cpp
+++ b/src/mongo/db/exec/multi_plan.cpp
@@ -364,7 +364,7 @@ void MultiPlanStage::removeRejectedPlans() {
}
size_t startIndex = 1;
if (_backupPlanIdx != kNoSuchPlan) {
- if (_bestPlanIdx != 1) {
+ if (_backupPlanIdx != 1) {
std::swap(_children[_backupPlanIdx], _children[1]);
std::swap(_candidates[_backupPlanIdx], _candidates[1]);
_backupPlanIdx = 1;