Skip to content

Commit

Permalink
Stop defaulting moduleType to ['node'] under npm. Use auto-detection …
Browse files Browse the repository at this point in the history
…instead.
  • Loading branch information
unscriptable committed Aug 18, 2014
1 parent 0d1013c commit 2532306
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 7 deletions.
1 change: 0 additions & 1 deletion lib/convert/npm.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ function npmFixups (data) {
if (typeof data.browser === 'object') {
data.mapFunc = npmBrowserMap(normalizeMap(data.browser, path.joinPaths(data.name, data.main)));
}
if (!data.moduleType) data.moduleType = ['node'];
if (data.directories && data.directories.lib) {
data.location = path.joinPaths(data.rootUrl, data.directories.lib);
}
Expand Down
6 changes: 0 additions & 6 deletions test/lib/convert/npm.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,12 +45,6 @@ buster.testCase('lib/convert/npm', {
data = npmFixups(data);
assert.isFunction(data.mapFunc);
},
'should provide moduleType if missing': function () {
var npmFixups = npm.npmFixups;
var data = createData();
data = npmFixups(data);
assert.isArray(data.moduleType);
},
'should adopt directories.lib of metadata as location': function () {
var npmFixups = npm.npmFixups;
var data = createData();
Expand Down

0 comments on commit 2532306

Please sign in to comment.