CS212-Projects-express/node_modules/call-bind/callBound.js
cdez 60087976ca Switched over to ExpressJS Hosting
++ CS212-Projects file copy
++ public folder
++ node stuff
2023-04-10 15:14:27 -07:00

15 lines
413 B
JavaScript

'use strict';
var GetIntrinsic = require('get-intrinsic');
var callBind = require('./');
var $indexOf = callBind(GetIntrinsic('String.prototype.indexOf'));
module.exports = function callBoundIntrinsic(name, allowMissing) {
var intrinsic = GetIntrinsic(name, !!allowMissing);
if (typeof intrinsic === 'function' && $indexOf(name, '.prototype.') > -1) {
return callBind(intrinsic);
}
return intrinsic;
};