You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

is-plain-array.js 283B

1234567891011
  1. "use strict";
  2. var isArray = Array.isArray, getPrototypeOf = Object.getPrototypeOf;
  3. module.exports = function (obj) {
  4. var proto;
  5. if (!obj || !isArray(obj)) return false;
  6. proto = getPrototypeOf(obj);
  7. if (!isArray(proto)) return false;
  8. return !isArray(getPrototypeOf(proto));
  9. };