debian-mirror-gitlab/core-js/es/instance/bind.js

9 lines
261 B
JavaScript
Raw Normal View History

2019-09-25 13:30:05 +05:30
var bind = require('../function/virtual/bind');
var FunctionPrototype = Function.prototype;
module.exports = function (it) {
var own = it.bind;
return it === FunctionPrototype || (it instanceof Function && own === FunctionPrototype.bind) ? bind : own;
};