Skip to content

Commit

Permalink
fix cluster_client
Browse files Browse the repository at this point in the history
  • Loading branch information
tsullivan committed Mar 11, 2020
1 parent fbbf580 commit 1cf768d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/core/server/elasticsearch/cluster_client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,9 @@ const callAPI = async (
const request = api.call(apiContext, clientParams);
if (options.signal) {
options.signal.addEventListener('abort', () => {
request.abort();
if (typeof request.abort === 'function') {
request.abort();
}
reject(new Error('Request was aborted'));
});
}
Expand Down

0 comments on commit 1cf768d

Please sign in to comment.