From dba0185b5955293829aa1cdfb908b3eda16697fd Mon Sep 17 00:00:00 2001 From: akannalathws3 Date: Tue, 3 Oct 2017 11:01:52 -0700 Subject: [PATCH 1/2] Add ability to handle connection errors --- index.js | 1 + 1 file changed, 1 insertion(+) diff --git a/index.js b/index.js index fad7d95..5f669a3 100644 --- a/index.js +++ b/index.js @@ -74,6 +74,7 @@ var new_client = function(sdk_key, config) { } config.logger.error("[LaunchDarkly]", error); + client.emit('error') // Allow conneciton error handling } else if (!init_complete) { init_complete = true; From 4610ad6f47d13b9c673af21616c1628387178045 Mon Sep 17 00:00:00 2001 From: akannalathws3 Date: Tue, 3 Oct 2017 11:13:57 -0700 Subject: [PATCH 2/2] Change error emit string --- index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.js b/index.js index 5f669a3..97949f7 100644 --- a/index.js +++ b/index.js @@ -74,7 +74,7 @@ var new_client = function(sdk_key, config) { } config.logger.error("[LaunchDarkly]", error); - client.emit('error') // Allow conneciton error handling + client.emit('connectError') // Allow conneciton error handling } else if (!init_complete) { init_complete = true;