Skip to content

Commit 7ccb155

Browse files
committed
Ensure, that each (concurrent) plugin usage has its own options
1 parent 5cfb600 commit 7ccb155

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

es6.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ define([
4747
var excludedOptions = ['extraPlugins', 'resolveModuleSource'];
4848
var pluginOptions = _module.config();
4949
var fileExtension = pluginOptions.fileExtension || '.js';
50-
var options = {
50+
var defaultOptions = {
5151
plugins: (pluginOptions.extraPlugins || []).concat([
5252
'transform-modules-amd',
5353
[
@@ -60,7 +60,7 @@ define([
6060
};
6161
for (var key in pluginOptions) {
6262
if (pluginOptions.hasOwnProperty(key) && excludedOptions.indexOf(key) < 0) {
63-
options[key] = pluginOptions[key];
63+
defaultOptions[key] = pluginOptions[key];
6464
}
6565
}
6666

@@ -71,6 +71,10 @@ return {
7171
var sourceFileName = name + fileExtension;
7272
var url = req.toUrl(sourceFileName);
7373

74+
var options = {};
75+
for (var key in defaultOptions) {
76+
options[key] = defaultOptions[key];
77+
}
7478
options.sourceFileName = sourceFileName;
7579
options.sourceMap = config.isBuild ? false : 'inline';
7680

0 commit comments

Comments
 (0)