Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -272,6 +272,8 @@ Its pretty simple to register a custom strategy. There are 3 things the object

Example:

always.js:

var AlwaysPass = function (config) { this.config };
AlwaysPass.prototype.check = function (callback) {
callback(true);
Expand All @@ -281,5 +283,8 @@ Example:
// no op
};

require('./upbeat').registerCallback('always-pass', AlwaysPass);
module.exports = AlwaysPass;

And then add to bin/upbeat, though the path is relative to lib/upbeat/

upbeat.registerStrategy('always-pass', '../../always.js');