Spaces:
Runtime error
Runtime error
File size: 308 Bytes
0e27770 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | /**
* Check if `fn` is a function.
*
* @param {Function} fn
* @return {Boolean}
* @api private
*/
var isObject = require('./is-object');
function isFunction(fn) {
var tag = isObject(fn) ? Object.prototype.toString.call(fn) : '';
return tag === '[object Function]';
}
module.exports = isFunction;
|