Socket
Socket
Sign inDemoInstall

bluebird

Package Overview
Dependencies
0
Maintainers
1
Versions
223
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.8.2-1 to 0.8.2-2

50

API.md

@@ -105,3 +105,3 @@ #API Reference

Note that it isn't really about raw memory - I know you have plenty. It's about the additional GC work which uses CPU.
#####`.then([Function fulfilledHandler] [, Function rejectedHandler ] [, Function progressHandler ])` -> `Promise`

@@ -139,3 +139,3 @@

}).catch(TypeError, function(e){
//If a is defined, will end up here because
//If a is defined, will end up here because
//it is a type error to reference property of undefined

@@ -149,3 +149,3 @@ }).catch(ReferenceError, function(e){

```
You may also add multiple filters for a catch handler:

@@ -164,3 +164,3 @@

```
For a paramater to be considered a type of error that you want to filter, you need the constructor to have its `.prototype` property be `instanceof Error`.

@@ -207,5 +207,5 @@

```
*For compatibility with earlier ECMAScript version, an alias `.caught()` is provided for `.catch()`.*
#####`.finally(Function handler)` -> `Promise`

@@ -232,3 +232,3 @@

```
This example doesn't work as intended because the `then` handler actually swallows the exception and returns `undefined` for any further chainers.

@@ -255,3 +255,3 @@

The `.finally` works like [Q's finally method](https://github.com/kriskowal/q/wiki/API-Reference#promisefinallycallback).
*For compatibility with earlier ECMAScript version, an alias `.lastly()` is provided for `.finally()`.*

@@ -359,3 +359,3 @@

at Object.InjectedScript._evaluateAndWrap (<anonymous>:540:52)
at Object.InjectedScript.evaluate (<anonymous>:459:21)
at Object.InjectedScript.evaluate (<anonymous>:459:21)

@@ -372,3 +372,3 @@ While with long stack traces disabled, you would get:

at MutationObserver.Promise$_Deferred (<anonymous>:433:17)
On client side, long stack traces currently only work in Firefox and Chrome.

@@ -413,3 +413,3 @@

Gives you a callback representation of the `PromiseResolver`. Note that this is not a method but a property. The callback accepts error object in first argument and success values on the 2nd parameter and the rest, I.E. node js conventions.
Gives you a callback representation of the `PromiseResolver`. Note that this is not a method but a property. The callback accepts error object in first argument and success values on the 2nd parameter and the rest, I.E. node js conventions.

@@ -474,3 +474,3 @@ If the the callback is called with multiple success values, the resolver fullfills its promise with an array of the values.

Normally using when using `.then` the code would be like:
Normally when using `.then` the code would be like:

@@ -485,3 +485,3 @@ ```js

This is useful when the results are not conceptually items of the same list.
This is useful when the `results` array contains items that are not conceptually items of the same list.

@@ -654,3 +654,3 @@ #####`.map(Function mapper)` -> `Promise`

```
Synchronous inspection API allows you to do this like so:

@@ -810,2 +810,18 @@

**Tip**
Use [`.spread`](#spreadfunction-fulfilledhandler--function-rejectedhandler----promise) with APIs that have multiple success values:
```js
var Promise = require("bluebird");
var request = Promise.promisify(require('request'));
request("http://www.google.com").spread(function(request, body) {
console.log(body);
}).catch(function(err) {
console.error(err);
});
```
The above uses [request](https://github.com/mikeal/request) library which has a callback signature of multiple success values.
#####`Promise.promisify(Object target)` -> `Object`

@@ -817,3 +833,3 @@

Promisifies the entire object by going iterating through the object's properties and creating an async equivalent of each function on the object and its prototype chain. The promisified method name will be the original method name postfixed with `Async`. Returns the input object.
Promisifies the entire object by going through the object's properties and creating an async equivalent of each function on the object and its prototype chain. The promisified method name will be the original method name postfixed with `Async`. Returns the input object.

@@ -914,3 +930,3 @@ Note that the original methods on the object are not overwritten but new methods are created with the `Async`-postfix. For example, if you `promisifyAll()` the node.js `fs` object use `fs.statAsync()` to call the promisified `stat` method.

...
When called, the coroutine function will start an instance of the generator and returns a promise for its final value.

@@ -995,2 +1011,2 @@

Passing no value or a non-function will have the effect of removing any kind of handling for possibly unhandled rejections.
Passing no value or a non-function will have the effect of removing any kind of handling for possibly unhandled rejections.
{
"name": "bluebird",
"description": "Full featured Promises/A+ implementation with exceptionally good performance",
"version": "0.8.2-1",
"version": "0.8.2-2",
"keywords": [

@@ -6,0 +6,0 @@ "promise",

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc