Skip to content

Instantly share code, notes, and snippets.

@bcoe
Created September 12, 2011 20:11
Show Gist options
  • Save bcoe/1212252 to your computer and use it in GitHub Desktop.
Save bcoe/1212252 to your computer and use it in GitHub Desktop.
before.js
exports.func = function(options, callback) {
if (typeof(options) === 'function') {
callback = options;
options = {};
}
callback = callback || function() {};
// ... Function body.
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment