[Pkg-javascript-commits] [node-module-deps] 311/444: make opts.modules always defined
Bastien Roucariès
rouca at moszumanska.debian.org
Fri Dec 15 09:48:08 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 f33c2d123ec2696b6330f65dff246bf3c47b9100
Author: James Halliday <mail at substack.net>
Date: Wed Nov 19 02:45:52 2014 +0100
make opts.modules always defined
---
index.js | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/index.js b/index.js
index 5da1830..21024fd 100644
--- a/index.js
+++ b/index.js
@@ -43,7 +43,8 @@ function Deps (opts) {
this.transforms = [].concat(opts.transform).filter(Boolean);
this.globalTransforms = [].concat(opts.globalTransform).filter(Boolean);
this.resolver = opts.resolve || browserResolve;
- this.options = opts;
+ this.options = copy(opts || {});
+ if (!this.options.modules) this.options.modules = {};
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