Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

when

Package Overview
Dependencies
Maintainers
1
Versions
63
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

when - npm Package Compare versions

Comparing version 1.4.2 to 1.4.3

2

package.json
{
"name": "when",
"version": "1.4.2",
"version": "1.4.3",
"description": "A lightweight Promise and when() implementation, plus other async goodies.",

@@ -5,0 +5,0 @@ "keywords": ["promises", "when", "async", "cujo"],

@@ -12,2 +12,6 @@ # when.js [![Build Status](https://secure.travis-ci.org/cujojs/when.png)](http://travis-ci.org/cujojs/when)

### 1.4.3
* Fix for infinite promise coercion between when.js and Q (See [#50](https://github.com/cujojs/when/issues/50)). Thanks [@kriskowal](https://github.com/kriskowal) and [@domenic](https://github.com/domenic)
### 1.4.2

@@ -14,0 +18,0 @@

@@ -10,3 +10,3 @@ /** @license MIT License (c) copyright B Cavalier & J Hann */

*
* @version 1.4.2
* @version 1.4.3
*/

@@ -83,2 +83,13 @@

// Some promises, particularly Q promises, provide a valueOf method that
// attempts to synchronously return the fulfilled value of the promise, or
// returns the unresolved promise itself. Attempting to break a fulfillment
// value out of a promise appears to be necessary to break cycles between
// Q and When attempting to coerce each-other's promises in an infinite loop.
// For promises that do not implement "valueOf", the Object#valueOf is harmless.
// See: https://github.com/kriskowal/q/issues/106
if (promiseOrValue != null && typeof promiseOrValue.valueOf === "function") {
promiseOrValue = promiseOrValue.valueOf();
}
if(isPromise(promiseOrValue)) {

@@ -701,3 +712,6 @@ // It looks like a thenable, but we don't know where it came from,

i = 0;
arr = new Object(this);
// This generates a jshint warning, despite being valid
// "Missing 'new' prefix when invoking a constructor."
// See https://github.com/jshint/jshint/issues/392
arr = Object(this);
len = arr.length >>> 0;

@@ -704,0 +718,0 @@ args = arguments;

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc