summaryrefslogtreecommitdiff
path: root/src/mongo/db/commands/user_management_commands.cpp
diff options
context:
space:
mode:
authorRuoxin Xu <ruoxin.xu@mongodb.com>2020-10-29 12:14:01 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2021-01-07 11:20:50 +0000
commit90c89d33c400d2f1eb8972170b7a17e3315c4198 (patch)
tree2aaee3468e4350950b546b2b24783d9ddc2d8e2e /src/mongo/db/commands/user_management_commands.cpp
parent66cdb6d0fccf3b65c61a1bea5d6171591d21c9da (diff)
downloadmongo-90c89d33c400d2f1eb8972170b7a17e3315c4198.tar.gz
SERVER-51649 Convert aggregate command input to IDL
Diffstat (limited to 'src/mongo/db/commands/user_management_commands.cpp')
-rw-r--r--src/mongo/db/commands/user_management_commands.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/mongo/db/commands/user_management_commands.cpp b/src/mongo/db/commands/user_management_commands.cpp
index f32b686f5a6..0d3387048fb 100644
--- a/src/mongo/db/commands/user_management_commands.cpp
+++ b/src/mongo/db/commands/user_management_commands.cpp
@@ -65,6 +65,7 @@
#include "mongo/db/jsobj.h"
#include "mongo/db/operation_context.h"
#include "mongo/db/ops/write_ops.h"
+#include "mongo/db/pipeline/aggregation_request_helper.h"
#include "mongo/db/query/cursor_response.h"
#include "mongo/db/repl/replication_coordinator.h"
#include "mongo/db/service_context.h"
@@ -1417,13 +1418,13 @@ UsersInfoReply CmdUMCTyped<UsersInfoCommand, UsersInfoReply, UMCInfoParams>::Inv
DBDirectClient client(opCtx);
rpc::OpMsgReplyBuilder replyBuilder;
- AggregationRequest aggRequest(AuthorizationManager::usersCollectionNamespace,
- std::move(pipeline));
+ AggregateCommand aggRequest(AuthorizationManager::usersCollectionNamespace,
+ std::move(pipeline));
// Impose no cursor privilege requirements, as cursor is drained internally
uassertStatusOK(runAggregate(opCtx,
AuthorizationManager::usersCollectionNamespace,
aggRequest,
- aggRequest.serializeToCommandObj().toBson(),
+ aggregation_request_helper::serializeToCommandObj(aggRequest),
PrivilegeVector(),
&replyBuilder));
auto bodyBuilder = replyBuilder.getBodyBuilder();