Repositorio del curso CCOM4030 el semestre B91 del proyecto Paz para la Mujer

is_arguments.js 641B

1234567891011121314151617181920
  1. var supportsArgumentsClass = (function(){
  2. return Object.prototype.toString.call(arguments)
  3. })() == '[object Arguments]';
  4. exports = module.exports = supportsArgumentsClass ? supported : unsupported;
  5. exports.supported = supported;
  6. function supported(object) {
  7. return Object.prototype.toString.call(object) == '[object Arguments]';
  8. };
  9. exports.unsupported = unsupported;
  10. function unsupported(object){
  11. return object &&
  12. typeof object == 'object' &&
  13. typeof object.length == 'number' &&
  14. Object.prototype.hasOwnProperty.call(object, 'callee') &&
  15. !Object.prototype.propertyIsEnumerable.call(object, 'callee') ||
  16. false;
  17. };