bluebird
Advanced tools
Comparing version 2.10.1 to 2.10.2
@@ -0,1 +1,7 @@ | ||
## 2.10.2 (2015-10-01) | ||
Features: | ||
- `.timeout()` now takes a custom error object as second argument | ||
## 2.10.1 (2015-09-21) | ||
@@ -2,0 +8,0 @@ |
@@ -8,6 +8,12 @@ "use strict"; | ||
if (!promise.isPending()) return; | ||
if (typeof message !== "string") { | ||
message = "operation timed out"; | ||
var err; | ||
if(!util.isPrimitive(message) && (message instanceof Error)) { | ||
err = message; | ||
} else { | ||
if (typeof message !== "string") { | ||
message = "operation timed out"; | ||
} | ||
err = new TimeoutError(message); | ||
} | ||
var err = new TimeoutError(message); | ||
util.markAsOriginatingFromRejection(err); | ||
@@ -14,0 +20,0 @@ promise._attachExtraTrace(err); |
{ | ||
"name": "bluebird", | ||
"description": "Full featured Promises/A+ implementation with exceptionally good performance", | ||
"version": "2.10.1", | ||
"version": "2.10.2", | ||
"keywords": [ | ||
@@ -6,0 +6,0 @@ "promise", |
@@ -467,3 +467,3 @@ <a href="http://promisesaplus.com/"> | ||
This enables output from the test and may give a better idea where the test is failing. The paramter to `--run` can be any file name located in `test/mocha` folder. | ||
This enables output from the test and may give a better idea where the test is failing. The parameter to `--run` can be any file name located in `test/mocha` folder. | ||
@@ -470,0 +470,0 @@ #### Testing in browsers |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
441547
8906