diff options
Diffstat (limited to 'src/mongo/db/s/shard_server_op_observer.cpp')
-rw-r--r-- | src/mongo/db/s/shard_server_op_observer.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mongo/db/s/shard_server_op_observer.cpp b/src/mongo/db/s/shard_server_op_observer.cpp index f8877f53aed..fd5f48278aa 100644 --- a/src/mongo/db/s/shard_server_op_observer.cpp +++ b/src/mongo/db/s/shard_server_op_observer.cpp @@ -488,7 +488,7 @@ void ShardServerOpObserver::onCreateCollection(OperationContext* opCtx, // TODO (SERVER-52778): Delete the lines below once all usages of // ScopedAllowImplicitCollectionCreate_UNSAFE have been removed auto* const csr = CollectionShardingRuntime::get(opCtx, collectionName); - if (opCtx->writesAreReplicated() && !csr->getCurrentMetadataIfKnown()) { + if (!csr->getCurrentMetadataIfKnown()) { csr->setFilteringMetadata(opCtx, CollectionMetadata()); } } |