summaryrefslogtreecommitdiff
path: root/src/mongo/db/commands/command_mirroring_test.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/db/commands/command_mirroring_test.cpp')
-rw-r--r--src/mongo/db/commands/command_mirroring_test.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mongo/db/commands/command_mirroring_test.cpp b/src/mongo/db/commands/command_mirroring_test.cpp
index 99db08a6df5..6afb28d8718 100644
--- a/src/mongo/db/commands/command_mirroring_test.cpp
+++ b/src/mongo/db/commands/command_mirroring_test.cpp
@@ -61,7 +61,7 @@ public:
bob << commandName() << coll;
bob << "lsid" << _lsid.toBSON();
- for (auto arg : args) {
+ for (const auto& arg : args) {
bob << arg.firstElement();
}
@@ -233,7 +233,7 @@ public:
void checkFieldNamesAreAllowed(BSONObj& mirroredObj) {
const auto possibleKeys = getAllowedKeys();
- for (auto key : mirroredObj.getFieldNames<std::set<std::string>>()) {
+ for (const auto& key : mirroredObj.getFieldNames<std::set<std::string>>()) {
ASSERT(std::find(possibleKeys.begin(), possibleKeys.end(), key) != possibleKeys.end());
}
}