Commit b7b9bee6 authored by Hannah Stepanek's avatar Hannah Stepanek

Only emit end if searchClient is done searching

Previously `end` was emitted after each getBatch call in the
searchClient, now it is emitted once after all batches are
complete.
parent d7a959c1
......@@ -74,11 +74,6 @@ class SearchClient extends EventEmitter {
return;
}
self.emit('error', err);
})
.then(function() {
if (self._canceled) {
return;
}
self.emit('end');
});
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment