UNPKG

forgot

Version:

Forgot the exceptions function throws, just go on

9 lines (7 loc) 194 B
function isFunction(obj) { return toString.call(obj) === '[object Function]'; } module.exports = function(fn) { if(!isFunction(fn)) return; try {return fn();} catch(e) {console.error(e);} }