prevent callback to call twice
{ Error: Request Timeout after 30000ms
at /usr/local/app/node_modules/elasticsearch/src/lib/transport.js:362:15
at Timeout.<anonymous> (/usr/local/app/node_modules/elasticsearch/src/lib/transport.js:391:7)
at ontimeout (timers.js:436:11)
at tryOnTimeout (timers.js:300:5)
at listOnTimeout (timers.js:263:5)
at Timer.processTimers (timers.js:223:10)
status: undefined,
displayName: 'RequestTimeout',
message: 'Request Timeout after 30000ms',
body: undefined }
Error [ERR_MULTIPLE_CALLBACK]: Callback called multiple times
at ElasticsearchTransformer.afterTransform (_stream_transform.js:85:31)
at runCallback (timers.js:705:18)
at tryOnImmediate (timers.js:676:5)
at processImmediate (timers.js:658:5)
Edited by Tobinsk