Skip to content

Commit

Permalink
migrate away from rest_total_hits_as_int
Browse files Browse the repository at this point in the history
  • Loading branch information
flash1293 committed Nov 30, 2020
1 parent a2b71f8 commit 4221934
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1187,7 +1187,7 @@ function GraphWorkspace(options) {

// Search for connections between the selected nodes.
searcher(self.options.indexName, searchReq, function (data) {
const numDocsMatched = data.hits.total;
const numDocsMatched = data.hits.total.value;
const buckets = data.aggregations.matrix.buckets;
const vertices = nodesForLinking.map(function (existingNode) {
return {
Expand Down
2 changes: 1 addition & 1 deletion x-pack/plugins/graph/server/routes/search.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ export function registerSearchRoute({
resp: await callCluster('search', {
index: request.body.index,
body: request.body.body,
rest_total_hits_as_int: true,
track_total_hits: true,
ignore_throttled: !includeFrozen,
}),
},
Expand Down

0 comments on commit 4221934

Please sign in to comment.