Closed babakyakhchali closed 6 years ago
Listen for the error
event. It will emit anytime an error happens:
var conn = new esl.Connection(...);
conn.on('error', function (err) {
// handle err
}
thank you you are right and it is working.
On Thu, Sep 7, 2017 at 3:03 AM, Chad Engler notifications@github.com wrote:
Listen for the error event. It will emit anytime an error happens:
var conn = new esl.Connection(...); conn.on('error', function (err) { // handle err }
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/englercj/node-esl/issues/68#issuecomment-327606494, or mute the thread https://github.com/notifications/unsubscribe-auth/AD3Vk7cB2OEeg9qp-3jLysXhptGZtaBNks5sfwNBgaJpZM4POFvx .
Hi how can network errors be handled? something like this: Error: connect ECONNREFUSED 192.168.2.18:8021 constructor only gets a callback which is called after successful connection. but what if esl server is down or not reachable?