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.6.0 to 1.6.1

2

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

@@ -5,0 +5,0 @@ "keywords": ["promise", "promises", "deferred", "deferreds", "when", "async", "asynchronous", "cujo"],

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

### 1.6.1
* Fix for accidental coercion of non-promises. See [#62](https://github.com/cujojs/when/issues/60).
### 1.6.0

@@ -11,0 +15,0 @@

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

*
* @version 1.6.0
* @version 1.6.1
*/

@@ -84,4 +84,3 @@

} else {
// It's not a when.js promise.
// Check to see if it's a foreign promise or a value.
// It's not a when.js promise. See if it's a foreign promise or a value.

@@ -95,3 +94,5 @@ // Some promises, particularly Q promises, provide a valueOf method that

// See: https://github.com/kriskowal/q/issues/106
if (promiseOrValue != null && typeof promiseOrValue.valueOf === 'function') {
// IMPORTANT: Must check for a promise here, since valueOf breaks other things
// like Date.
if (isPromise(promiseOrValue) && typeof promiseOrValue.valueOf === 'function') {
promiseOrValue = promiseOrValue.valueOf();

@@ -98,0 +99,0 @@ }

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