Description
while writing unit tests for the UserQueryManager i noticed the following check for collision between the bound value and the offset:
XPathQueryBuilder builder = new XPathQueryBuilder(); [...] Value bound = builder.getBound(); if (bound != null && offset > 0) { log.warn("Found bound {} and offset {} in limit. Discarding offset.", builder.getBound(), offset); offset = 0; }
however, the XPathQueryBuilder already takes care of resetting offset/bound if the other limit is set. The extra check in the query manager is therefore superfluous and the statement will never be reached IMO.
cc: alex.parvulescu, mduerig