Browse Source

more generic fix for issue #175

pull/177/head
Alexey Makeyev 9 years ago
parent
commit
0d235b9ca6
  1. 4
      json-path/src/main/java/com/jayway/jsonpath/internal/path/PredicatePathToken.java

4
json-path/src/main/java/com/jayway/jsonpath/internal/path/PredicatePathToken.java

@ -72,9 +72,13 @@ public class PredicatePathToken extends PathToken {
Predicate.PredicateContext ctx = new PredicateContextImpl(obj, root, configuration, evaluationContext.documentEvalCache()); Predicate.PredicateContext ctx = new PredicateContextImpl(obj, root, configuration, evaluationContext.documentEvalCache());
for (Predicate predicate : predicates) { for (Predicate predicate : predicates) {
try {
if (!predicate.apply(ctx)) { if (!predicate.apply(ctx)) {
return false; return false;
} }
} catch (InvalidPathException e) {
return false;
}
} }
return true; return true;
} }

Loading…
Cancel
Save