(function(){var e=function(){var b=this.events={};return{on:function(a,c){"string"!==typeof a||"function"!==typeof c?console.warn("Incorrect event registration. Event name must be a string and callback must be a function"):(b.hasOwnProperty(a)||(b[a]=[]),b[a].push(c),console.dir(b))},off:function(a,c){if("string"!==typeof a)console.warn("Incorrect event registration. Event name must be a string.");else{"undefined"===typeof c&&delete b[a];var d=b[a].indexOf(c);b[a].splice(d,1);0===b[a].length&&delete b[a]}},
emit:function(){var a=[].slice.call(arguments,0),c=a.shift();if("string"===typeof c||b.hasOwnProperty(c)){console.dir(b);for(var c=b[c],d=0;d<c.length;d++)c[d].apply(this,a)}}}}();plug.from("eventPrototype",e)})();
