Browse Source

build configuration with provided mapper

pull/683/head
Ajay Mandvekar 4 years ago
parent
commit
7321f6b289
  1. 2
      json-path/src/main/java/com/jayway/jsonpath/internal/filter/ValueNodes.java

2
json-path/src/main/java/com/jayway/jsonpath/internal/filter/ValueNodes.java

@ -624,7 +624,7 @@ public interface ValueNodes {
public ValueNode evaluate(Predicate.PredicateContext ctx) {
if (isExistsCheck()) {
try {
Configuration c = Configuration.builder().jsonProvider(ctx.configuration().jsonProvider()).options(Option.REQUIRE_PROPERTIES).build();
Configuration c = Configuration.builder().jsonProvider(ctx.configuration().jsonProvider()).mappingProvider(ctx.configuration().mappingProvider()).options(Option.REQUIRE_PROPERTIES).build();
Object result = path.evaluate(ctx.item(), ctx.root(), c).getValue(false);
return result == JsonProvider.UNDEFINED ? FALSE : TRUE;
} catch (PathNotFoundException e) {

Loading…
Cancel
Save