From e0a505e2a8bfe59d8bdfc4e5a25aef4861d58fcf Mon Sep 17 00:00:00 2001 From: Tess Avitabile Date: Thu, 14 Sep 2017 16:40:46 -0400 Subject: SERVER-30731 MatchExpressionParser::parse() should require an ExpressionContext --- src/mongo/db/catalog/coll_mod.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/mongo/db/catalog/coll_mod.cpp') diff --git a/src/mongo/db/catalog/coll_mod.cpp b/src/mongo/db/catalog/coll_mod.cpp index 59e8623ac7a..1a24d9a8caa 100644 --- a/src/mongo/db/catalog/coll_mod.cpp +++ b/src/mongo/db/catalog/coll_mod.cpp @@ -180,7 +180,7 @@ StatusWith parseCollModRequest(OperationContext* opCtx, // instances, as indicated by !validateFeaturesAsMaster. allowedFeatures |= MatchExpressionParser::kJSONSchema; } - auto statusW = coll->parseValidator(e.Obj(), allowedFeatures); + auto statusW = coll->parseValidator(opCtx, e.Obj(), allowedFeatures); if (!statusW.isOK()) { if (statusW.getStatus().code() == ErrorCodes::JSONSchemaNotAllowed) { // The default error message for disallowed $jsonSchema is not descriptive -- cgit v1.2.1