This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function Guvna(options) { | |
// error checking | |
if (!options.list || !options.callback || !options.done) { | |
console.log('ERROR: missing required option - { list: [], callback: fn(), done: fn() }'); | |
return false; | |
} | |
// assign vars | |
this.list = options.list; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* A simple way to extend the EventEmitter to classes with the class.extend module in NodeJS | |
*/ | |
var Class = require('class.extend'), | |
events = require('events'); | |
var Events = Class.extend({ | |
init: function() { events.EventEmitter.call(this); } | |
}); |
NewerOlder