source: node_modules/core-js-pure/internals/get-built-in.js

main
Last change on this file was d24f17c, checked in by Aleksandar Panovski <apano77@…>, 15 months ago

Initial commit

  • Property mode set to 100644
File size: 493 bytes
RevLine 
[d24f17c]1'use strict';
2var path = require('../internals/path');
3var global = require('../internals/global');
4var isCallable = require('../internals/is-callable');
5
6var aFunction = function (variable) {
7 return isCallable(variable) ? variable : undefined;
8};
9
10module.exports = function (namespace, method) {
11 return arguments.length < 2 ? aFunction(path[namespace]) || aFunction(global[namespace])
12 : path[namespace] && path[namespace][method] || global[namespace] && global[namespace][method];
13};
Note: See TracBrowser for help on using the repository browser.