mirror of https://github.com/status-im/metro.git
Treat package.json's first
Reviewed By: fkgozali Differential Revision: D5736600 fbshipit-source-id: f2947d4b1fb057ea33dd84e3c8cd878d5bfeda49
This commit is contained in:
parent
909480887e
commit
9254941133
|
@ -76,11 +76,12 @@ class HasteMap<TModule: Moduleish, TPackage: Packageish> extends EventEmitter {
|
|||
const promises = [];
|
||||
this._files.forEach(filePath => {
|
||||
if (!this._helpers.isNodeModulesDir(filePath)) {
|
||||
if (this._extensions.indexOf(path.extname(filePath).substr(1)) !== -1) {
|
||||
promises.push(this._processHasteModule(filePath));
|
||||
}
|
||||
if (filePath.endsWith(PACKAGE_JSON)) {
|
||||
promises.push(this._processHastePackage(filePath));
|
||||
} else if (
|
||||
this._extensions.indexOf(path.extname(filePath).substr(1)) !== -1
|
||||
) {
|
||||
promises.push(this._processHasteModule(filePath));
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue