1
0
mirror of https://github.com/node-red/node-red-nodes.git synced 2023-10-10 13:36:58 +02:00

Bump event listener limit up to 100

to close #327
This commit is contained in:
Dave Conway-Jones 2017-08-27 18:21:14 +01:00
parent 9a17460b0e
commit ee852bf060
No known key found for this signature in database
GPG Key ID: 81B04231572A9A2D
2 changed files with 4 additions and 7 deletions

View File

@ -110,6 +110,7 @@ module.exports = function(RED) {
var self = this;
if (this.pusher) {
var stream = this.pusher.stream();
stream.setMaxListeners(100);
var closing = false;
var tout;
stream.on('message', function(res) {
@ -144,12 +145,8 @@ module.exports = function(RED) {
this.on("close",function() {
if (tout) { clearTimeout(tout); }
closing = true;
try {
this.stream.close();
}
catch(err) {
// Ignore error if not connected
}
try { this.stream.close(); }
catch(err) { } // Ignore error if not connected
});
}
};

View File

@ -1,6 +1,6 @@
{
"name" : "node-red-node-pushbullet",
"version" : "0.0.11",
"version" : "0.0.12",
"description" : "A Node-RED node to send alerts via Pushbullet",
"dependencies" : {
"pushbullet": "~1.4.3",