1
0
mirror of https://github.com/redis/node-redis.git synced 2025-08-06 02:15:48 +03:00

Remove listener if not needed anymore and alawys end a client after a test

This commit is contained in:
Ruben Bridgewater
2015-10-29 15:04:47 +01:00
parent dc6fc9c113
commit 7718e219e9
3 changed files with 19 additions and 10 deletions

View File

@@ -115,7 +115,8 @@ RedisClient.prototype.install_stream_listeners = function() {
});
}
this.stream.on('connect', function () {
this.stream.once('connect', function () {
this.removeAllListeners("timeout");
self.on_connect();
});