Skip to content

Commit

Permalink
do not call score() twice
Browse files Browse the repository at this point in the history
  • Loading branch information
brwe committed Jan 2, 2014
1 parent d150a72 commit 39a5f79
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -168,8 +168,9 @@ public int nextDoc() throws IOException {

@Override
public float score() throws IOException {
return scoreCombiner.combine(subQueryBoost, scorer.score(),
function.score(scorer.docID(), scorer.score()), maxBoost);
float score = scorer.score();
return scoreCombiner.combine(subQueryBoost, score,
function.score(scorer.docID(), score), maxBoost);
}

@Override
Expand Down

0 comments on commit 39a5f79

Please sign in to comment.