log-errback
Logs the arguments from an errorback. A useful callback probe.
Last updated 5 years ago by bret .
ISC · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install log-errback 
SYNC missed versions from official npm registry.

log-errback

npm travis standard

Logs the arguments from an errorback. A useful callback probe.

Install

npm install log-errback

Usage

var logErrback = require('log-errback')

asyncFunction(logErrback.sync) // logs out the arguments it receives and does not call a callback

// say you have the following

asyncFunction(function(err, results) {
  if (err) throw(err)
  // do stuff with results
})

// Its not working and you want to dig into the callback arguments, you can insert
// logErrBack to log out whats getting passed into the callback

asyncFunction(logErrback(function(err, results) {
  if (err) throw(err)
  // do stuff with results
}))

Contributing

Contributions welcome! Please read the contributing guidelines first.

License

ISC

Current Tags

  • 1.0.3                                ...           latest (5 years ago)

4 Versions

  • 1.0.3                                ...           5 years ago
  • 1.0.2                                ...           5 years ago
  • 1.0.1                                ...           5 years ago
  • 1.0.0                                ...           5 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (1)
Dev Dependencies (3)
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |