[Pkg-javascript-commits] [node-module-deps] 335/444: Set `this.options.expose` default.
Bastien Roucariès
rouca at moszumanska.debian.org
Fri Dec 15 09:48:10 UTC 2017
This is an automated email from the git hooks/post-receive script.
rouca pushed a commit to branch master
in repository node-module-deps.
commit a4bb222cf587aec0145b552b6877da5439271c30
Author: Jesse McCarthy <git_commits at jessemccarthy.net>
Date: Thu Jan 15 14:39:46 2015 -0500
Set `this.options.expose` default.
---
index.js | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/index.js b/index.js
index 9ae6d31..91e22a3 100644
--- a/index.js
+++ b/index.js
@@ -49,6 +49,10 @@ function Deps (opts) {
this.resolver = opts.resolve || browserResolve;
this.options = copy(opts || {});
if (!this.options.modules) this.options.modules = {};
+
+ // If the caller passes options.expose, store resolved pathnames for exposed
+ // modules in it. If not, set it anyway so it's defined later.
+ if (!this.options.expose) this.options.expose = {};
this.pending = 0;
var topfile = path.join(this.basedir, '__fake.js');
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/node-module-deps.git
More information about the Pkg-javascript-commits
mailing list