diff options
Diffstat (limited to 'deps/npm/node_modules/which-module/index.js')
-rw-r--r-- | deps/npm/node_modules/which-module/index.js | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/deps/npm/node_modules/which-module/index.js b/deps/npm/node_modules/which-module/index.js new file mode 100644 index 0000000000..45559b7818 --- /dev/null +++ b/deps/npm/node_modules/which-module/index.js @@ -0,0 +1,9 @@ +'use strict' + +module.exports = function whichModule (exported) { + for (var i = 0, files = Object.keys(require.cache), mod; i < files.length; i++) { + mod = require.cache[files[i]] + if (mod.exports === exported) return mod + } + return null +} |