Browse Source

smallfix for deep scan predicate (though, kind of redundant, but logic is clearer)

pull/142/head
Alexey Makeyev 9 years ago
parent
commit
101ffa6090
  1. 2
      json-path/src/main/java/com/jayway/jsonpath/internal/token/ScanPathToken.java

2
json-path/src/main/java/com/jayway/jsonpath/internal/token/ScanPathToken.java

@ -183,7 +183,7 @@ public class ScanPathToken extends PathToken {
return true; return true;
} }
if (ctx.options().contains(Option.DEFAULT_PATH_LEAF_TO_NULL)) { if (propertyPathToken.isLeaf() && ctx.options().contains(Option.DEFAULT_PATH_LEAF_TO_NULL)) {
// In case of DEFAULT_PATH_LEAF_TO_NULL missing properties is not a problem. // In case of DEFAULT_PATH_LEAF_TO_NULL missing properties is not a problem.
return true; return true;
} }

Loading…
Cancel
Save