mocobeta commented on code in PR #931: URL: https://github.com/apache/lucene/pull/931#discussion_r884855095
########## lucene/core/src/java/org/apache/lucene/search/MaxScoreCache.java: ########## @@ -80,6 +82,9 @@ int getLevel(int upTo) throws IOException { /** Return the maximum score for the given {@code level}. */ float getMaxScoreForLevel(int level) throws IOException { + if (level < 0) { Review Comment: The original expression was `level == -1`. "smaller than zero" might be better here since there is an assumption that `level` is greater or equal to zero, I have no strong opinion on it though. -- 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