summaryrefslogtreecommitdiff
path: root/src/mongo/db/catalog/rename_collection.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/db/catalog/rename_collection.cpp')
-rw-r--r--src/mongo/db/catalog/rename_collection.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mongo/db/catalog/rename_collection.cpp b/src/mongo/db/catalog/rename_collection.cpp
index 111629b3fb4..08383c041bc 100644
--- a/src/mongo/db/catalog/rename_collection.cpp
+++ b/src/mongo/db/catalog/rename_collection.cpp
@@ -93,7 +93,7 @@ Status checkSourceAndTargetNamespaces(OperationContext* opCtx,
auto replCoord = repl::ReplicationCoordinator::get(opCtx);
if (opCtx->writesAreReplicated() && !replCoord->canAcceptWritesFor(opCtx, source))
- return Status(ErrorCodes::NotMaster,
+ return Status(ErrorCodes::NotWritablePrimary,
str::stream() << "Not primary while renaming collection " << source << " to "
<< target);