This API wraps an asynchronous function so that it can be called in a top-down manner within a fiber. If the asynchronous call fails, no error is thrown; instead, it is attached to the return value.
The API assumes that the function accepts a callback as its last parameter in the following format:
This is typical for virtually all asynchronous Node.js requests.
The API can also accept an object which contains a set of asynchronous functions, in which case it will act the same as the pjs.fiber.wrapAllNoFail() API.
- asynchronous function
- object containing asynchronous functions
Top-down function that returns an object with the following properties:
value: true or false
value: error object(if success is
value: response output(if success is
No exceptions are thrown by this API.