We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 651d5bd commit 83814a6Copy full SHA for 83814a6
src/mongo/db/query/query_request.cpp
@@ -621,8 +621,7 @@ Status QueryRequest::validate() const {
621
BSONElement sortElt = sortIt.next();
622
if (isTextScoreMeta(sortElt) || isShardNameMeta(sortElt)) {
623
BSONElement projElt = _proj[sortElt.fieldName()];
624
- if (projElt.eoo() || (isTextScoreMeta(sortElt) && !isTextScoreMeta(projElt)) ||
625
- (isShardNameMeta(sortElt) && !isShardNameMeta(projElt))) {
+ if (projElt.eoo() || (isTextScoreMeta(sortElt) && !isTextScoreMeta(projElt))) {
626
return Status(ErrorCodes::BadValue,
627
"must have $meta projection for all $meta sort keys");
628
}
0 commit comments