Browse Source

A getHits() was forgotten!

(cherry picked from commit 11b3053)
(cherry picked from commit 89294e9)
eBuildy 10 years ago
parent
commit
5c57db4aae
1 changed files with 1 additions and 1 deletions
  1. 1 1
      docs/java-api/search.asciidoc

+ 1 - 1
docs/java-api/search.asciidoc

@@ -63,7 +63,7 @@ SearchResponse scrollResp = client.prepareSearch(test)
 //Scroll until no hits are returned
 while (true) {
 
-    for (SearchHit hit : scrollResp.getHits()) {
+    for (SearchHit hit : scrollResp.getHits().getHits()) {
         //Handle the hit...
     }
     scrollResp = client.prepareSearchScroll(scrollResp.getScrollId()).setScroll(new TimeValue(600000)).execute().actionGet();