Joscorbe commented on a change in pull request #359:
URL: https://github.com/apache/jackrabbit-oak/pull/359#discussion_r711947384
##########
File path:
oak-store-document/src/main/java/org/apache/jackrabbit/oak/plugins/document/UpdateUtils.java
##########
@@ -150,6 +150,18 @@ public static boolean checkConditions(@NotNull Document
doc,
} else if (c.type == Condition.Type.NOTEQUALS && equal) {
return false;
}
+ } else if (c.type == Condition.Type.LESSTHAN) {
+ if (r != null) {
+ if (value instanceof Map) {
+ value = ((Map) value).get(r);
+ } else {
+ value = null;
+ }
+ }
+ if (value instanceof Comparable && c.value instanceof
Comparable) {
+ int lessThan = ((Comparable) value).compareTo(c.value);
+ return lessThan == -1;
+ }
Review comment:
I have removed all the logic related with "lessThan", as now I'm using
UpdateOp.max() as you proposed.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]