summaryrefslogtreecommitdiff
path: root/src/mongo/db/bson/dotted_path_support.cpp
diff options
context:
space:
mode:
authorAlberto Massari <alberto.massari@mongodb.com>2022-10-27 09:16:55 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2022-10-27 09:48:57 +0000
commit0c8f1abefdc0f6c09b2ecebc17f7dd7a958f9148 (patch)
tree73d75dfddf4ea97c1e3dd7e73804024e8e1aa3ab /src/mongo/db/bson/dotted_path_support.cpp
parent0413ae1e4ad6715c0b34f9318e638d72b9087365 (diff)
downloadmongo-0c8f1abefdc0f6c09b2ecebc17f7dd7a958f9148.tar.gz
SERVER-66511 Use traverseP expressions to compute sort keys
Diffstat (limited to 'src/mongo/db/bson/dotted_path_support.cpp')
-rw-r--r--src/mongo/db/bson/dotted_path_support.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mongo/db/bson/dotted_path_support.cpp b/src/mongo/db/bson/dotted_path_support.cpp
index 8bfc0483f3b..c6c4d107a3b 100644
--- a/src/mongo/db/bson/dotted_path_support.cpp
+++ b/src/mongo/db/bson/dotted_path_support.cpp
@@ -145,7 +145,7 @@ BSONElement extractElementAtPathOrArrayAlongPath(const BSONObj& obj, const char*
BSONElement sub;
if (p) {
- sub = obj.getField(std::string(path, p - path));
+ sub = obj.getField(StringData(path, p - path));
path = p + 1;
} else {
sub = obj.getField(path);