Skip to content

Commit

Permalink
fix: Search fails on casting ValueExpression
Browse files Browse the repository at this point in the history
* Search fails on some occasions when casting to StringValue or
  UntypedValue.
  * The Search engine probably is incosistent when it uses UntypedValue
    vs StringValue
  • Loading branch information
kennethmyhra committed Jul 30, 2019
1 parent 291d133 commit 9d8b40b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Spark.Mongo/Search/Searcher/MongoSearcher.cs
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ private Criterium CloseCriterium(Criterium crit, string resourceType, int level)
throw new ArgumentException(String.Format("None of the possible target resources support querying for parameter {0}", crit.ParamName));
}
crit.Operator = Operator.IN;
crit.Operand = new ChoiceValue(allKeys.Select(k => new StringValue(k)));
crit.Operand = new ChoiceValue(allKeys.Select(k => new UntypedValue(k)));
return crit;
}

Expand Down

0 comments on commit 9d8b40b

Please sign in to comment.