redis 3.0.1 → 3.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +0 -1
- package/index.js +6 -18
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -12,7 +12,6 @@
|
|
|
12
12
|
<a href="https://www.npmjs.com/package/redis"><img src="https://img.shields.io/npm/dm/redis.svg?style=flat-square" alt="NPM downloads"></a>
|
|
13
13
|
<a href="https://www.npmjs.com/package/redis"><img src="https://img.shields.io/npm/v/redis.svg?style=flat-square" alt="NPM version"></a>
|
|
14
14
|
<a href="https://travis-ci.org/NodeRedis/node-redis"><img src="https://travis-ci.org/NodeRedis/node-redis.svg?style=flat-square&branch=master" alt="Build Status" /></a>
|
|
15
|
-
<a href="https://ci.appveyor.com/project/BridgeAR/node-redis/branch/master"><img src="https://img.shields.io/appveyor/ci/BridgeAR/node-redis/master.svg?style=flat-square&label=Windows%20Tests" alt="Windows Tests" /></a>
|
|
16
15
|
<a href="https://coveralls.io/r/NodeRedis/node-redis?branch="><img src="https://coveralls.io/repos/NodeRedis/node-redis/badge.svg?style=flat-square&branch=" alt="Coverage Status" /></a>
|
|
17
16
|
<a href="https://twitter.com/NodeRedis"><img src="https://img.shields.io/twitter/follow/NodeRedis.svg?style=flat-square&colorA=1da1f2&colorB=&label=Follow%20on%20Twitter" alt="Follow on Twitter"></a>
|
|
18
17
|
</p>
|
package/index.js
CHANGED
|
@@ -556,12 +556,8 @@ RedisClient.prototype.connection_gone = function (why, error) {
|
|
|
556
556
|
if (this.retry_delay instanceof Error) {
|
|
557
557
|
error = this.retry_delay;
|
|
558
558
|
}
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
errorMessage += 'connection timeout exceeded.';
|
|
562
|
-
} else {
|
|
563
|
-
errorMessage += 'maximum connection attempts exceeded.';
|
|
564
|
-
}
|
|
559
|
+
|
|
560
|
+
var errorMessage = 'Redis connection in broken state: retry aborted.';
|
|
565
561
|
|
|
566
562
|
this.flush_and_error({
|
|
567
563
|
message: errorMessage,
|
|
@@ -581,13 +577,7 @@ RedisClient.prototype.connection_gone = function (why, error) {
|
|
|
581
577
|
}
|
|
582
578
|
|
|
583
579
|
if (this.retry_totaltime >= this.connect_timeout) {
|
|
584
|
-
var message = 'Redis connection in broken state: ';
|
|
585
|
-
if (this.retry_totaltime >= this.connect_timeout) {
|
|
586
|
-
message += 'connection timeout exceeded.';
|
|
587
|
-
} else {
|
|
588
|
-
message += 'maximum connection attempts exceeded.';
|
|
589
|
-
}
|
|
590
|
-
|
|
580
|
+
var message = 'Redis connection in broken state: connection timeout exceeded.';
|
|
591
581
|
this.flush_and_error({
|
|
592
582
|
message: message,
|
|
593
583
|
code: 'CONNECTION_BROKEN',
|
|
@@ -864,11 +854,9 @@ RedisClient.prototype.internal_send_command = function (command_obj) {
|
|
|
864
854
|
if (command_obj.args && command_obj.args.length) {
|
|
865
855
|
undefinedArgError.args = command_obj.args;
|
|
866
856
|
}
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
}
|
|
871
|
-
throw undefinedArgError;
|
|
857
|
+
// there is always a callback in this scenario
|
|
858
|
+
command_obj.callback(undefinedArgError);
|
|
859
|
+
return false;
|
|
872
860
|
} else {
|
|
873
861
|
// Seems like numbers are converted fast using string concatenation
|
|
874
862
|
args_copy[i] = '' + args[i];
|