massive update, probably broken
[dotfiles/.git] / .config / coc / extensions / node_modules / coc-prettier / node_modules / core-js / es / instance / index-of.js
index a5fa42a8cddd96edb82cb173da89b61b77a8f7ab..9dc9d04e73df54fe6eddc3071f9b4c2a8ba9da01 100644 (file)
@@ -1,8 +1,9 @@
-var indexOf = require('../array/virtual/index-of');
+var isPrototypeOf = require('../../internals/object-is-prototype-of');
+var method = require('../array/virtual/index-of');
 
 var ArrayPrototype = Array.prototype;
 
 module.exports = function (it) {
   var own = it.indexOf;
-  return it === ArrayPrototype || (it instanceof Array && own === ArrayPrototype.indexOf) ? indexOf : own;
+  return it === ArrayPrototype || (isPrototypeOf(ArrayPrototype, it) && own === ArrayPrototype.indexOf) ? method : own;
 };