summaryrefslogtreecommitdiff
path: root/src/mongo/db/commands.h
diff options
context:
space:
mode:
authorRishab Joshi <rishab.joshi@mongodb.com>2021-02-26 12:23:44 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2021-03-02 19:57:43 +0000
commit89763c85010ecdce122044486b090e7484514c51 (patch)
tree61716ff3e48b95d2c20810d4767ca5908f7a9276 /src/mongo/db/commands.h
parentf18d7ff55057815802fffba192af164972b4652a (diff)
downloadmongo-89763c85010ecdce122044486b090e7484514c51.tar.gz
SERVER-54812 Handle the case when find_and_modify request BSON object is
empty
Diffstat (limited to 'src/mongo/db/commands.h')
-rw-r--r--src/mongo/db/commands.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/mongo/db/commands.h b/src/mongo/db/commands.h
index dc1519c167b..9cf24dc3e55 100644
--- a/src/mongo/db/commands.h
+++ b/src/mongo/db/commands.h
@@ -1146,7 +1146,9 @@ public:
InvocationBaseInternal(OperationContext* opCtx,
const Command* command,
const OpMsgRequest& opMsgRequest)
- : CommandInvocation(command), _request{_parseRequest(opCtx, command, opMsgRequest)} {}
+ : CommandInvocation(command),
+ _request{_parseRequest(opCtx, command, opMsgRequest)},
+ _opMsgRequest{opMsgRequest} {}
protected:
const RequestType& request() const {
@@ -1174,6 +1176,8 @@ private:
}
RequestType _request;
+
+ const OpMsgRequest _opMsgRequest;
};
template <typename Derived>