The connection.executeAsync method sets async flag to true and calls connection.execute. This is inside connection.execute:
if(self.async) {
self.once('');
}
And generates:
Error: many only accepts instances of Function
at EventEmitter.many (/node_modules/modesl/node_modules/eventemitter2/lib/eventemitter2.js:244:13)
at EventEmitter.once (/node_modules/modesl/node_modules/eventemitter2/lib/eventemitter2.js:236:10)
at Connection.execute (/node_modules/modesl/lib/esl/Connection.js:433:14)
at Connection.executeAsync (/node_modules/modesl/lib/esl/Connection.js:462:10)
at Object.self.publicAPI.playback (/vedeu/lib/JavaScript/calld/Inbound.js:132:27)
at Object.Router.onMessage (/vedeu/daemons/calld/calld.js:108:47)
at null.<anonymous> (/vedeu/lib/JavaScript/router.js:41:22)
at emit (events.js:95:17)
at Socket._flush (/node_modules/zmq/lib/index.js:510:19)
at _zmq.onReady (/node_modules/zmq/lib/index.js:193:12)
Weird, looks like I just never actually implemented it. Just did a release for v1.1.3 that includes changes that should make it work. Sorry about that!
The connection.executeAsync method sets async flag to true and calls connection.execute. This is inside connection.execute:
And generates:
EventEmitter2 API is: