summaryrefslogtreecommitdiff
path: root/src/mongo/db/ops/parsed_update.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/db/ops/parsed_update.cpp')
-rw-r--r--src/mongo/db/ops/parsed_update.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mongo/db/ops/parsed_update.cpp b/src/mongo/db/ops/parsed_update.cpp
index d6a26fdaed2..9e084b2dfe5 100644
--- a/src/mongo/db/ops/parsed_update.cpp
+++ b/src/mongo/db/ops/parsed_update.cpp
@@ -94,12 +94,12 @@ namespace mongo {
// Only user updates should be checked. Any system or replication stuff should pass through.
// Config db docs shouldn't get checked for valid field names since the shard key can have
// a dot (".") in it.
- const bool shouldValidate = !(_request->isFromReplication() ||
+ const bool shouldValidate = !(!_txn->writesAreReplicated() ||
ns.isConfigDB() ||
_request->isFromMigration());
_driver.setLogOp(true);
- _driver.setModOptions(ModifierInterface::Options(_request->isFromReplication(),
+ _driver.setModOptions(ModifierInterface::Options(!_txn->writesAreReplicated(),
shouldValidate));
return _driver.parse(_request->getUpdates(), _request->isMulti());