diff options
author | jannaerin <golden.janna@gmail.com> | 2022-05-19 13:50:55 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2022-05-19 14:48:27 +0000 |
commit | 0419b6d14796177749c1921fb787a8c1d0e1faa3 (patch) | |
tree | daff9855d2aae5cd8dceb5011b3fe1fa135448e1 /src/mongo/db/namespace_string.h | |
parent | 5b63a432d152cafcd2e8479a28754c3d51d63baf (diff) | |
download | mongo-0419b6d14796177749c1921fb787a8c1d0e1faa3.tar.gz |
SERVER-66028 Include tenantId when constructing namespaces for change streams agg stages
Diffstat (limited to 'src/mongo/db/namespace_string.h')
-rw-r--r-- | src/mongo/db/namespace_string.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mongo/db/namespace_string.h b/src/mongo/db/namespace_string.h index e29f501a0df..38606ae3d4f 100644 --- a/src/mongo/db/namespace_string.h +++ b/src/mongo/db/namespace_string.h @@ -241,7 +241,7 @@ public: "namespaces cannot have embedded null characters", _ns.find('\0') == std::string::npos); - auto db = _dotIndex == std::string::npos ? ns : ns.substr(0, _dotIndex); + auto db = _dotIndex == std::string::npos ? ns : ns.substr(0, ns.find('.')); _dbName = DatabaseName(tenantId, db); } |