Skip to content
This repository was archived by the owner on Jan 6, 2021. It is now read-only.

API Enhancements

Latest
Compare
Choose a tag to compare
@NathanGRomano NathanGRomano released this 16 Aug 01:53
· 10 commits to master since this release

Updated the API to behave more like express using switched.

var bus = require('bus.io');
bus.on('some*', function (msg, next) {
  next();
});
bus.on(/event/, function (msg, next) {
  next(new Error('Some Error'));
});
bus.on(function (err, msg, next) {
  next();
});
bus.on('some event', function (msg, next) {
  msg.deliver();
});