gsmiller commented on a change in pull request #751: URL: https://github.com/apache/lucene/pull/751#discussion_r836685698
########## File path: lucene/facet/src/java/org/apache/lucene/facet/LongValueFacetCounts.java ########## @@ -348,6 +348,9 @@ private void increment(long value) { @Override public FacetResult getTopChildren(int topN, String dim, String... path) { + if (topN <= 0) { Review comment: By "spin-off issue," I just meant open a new Jira issue to capture the future work instead of tackling it now. The future work being seeing if there's a way to enforce this precondition check in a parent class common to our various implementations to avoid the copy/paste check. I think this PR should move forward. It's good progress! -- 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: issues-unsubscr...@lucene.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org