File tree Expand file tree Collapse file tree 1 file changed +5
-9
lines changed Expand file tree Collapse file tree 1 file changed +5
-9
lines changed Original file line number Diff line number Diff line change @@ -79,20 +79,16 @@ StubGenerator.prototype.build = function() {
79
79
var needsImportsReWritten = false ;
80
80
81
81
Object . keys ( imports ) . forEach ( function ( name ) {
82
- needsImportsReWritten = true ;
83
82
imports [ name ] . version = versionForModuleName ( name , this . basedir ) ;
84
83
} , this ) ;
85
84
86
- if ( needsImportsReWritten ) {
87
- fs . writeFileSync ( fullOutputPath , rewriteImports ( content , imports ) ) ;
88
- } else {
89
- fs . writeFileSync ( fullOutputPath , content ) ;
90
- }
85
+ fs . writeFileSync ( fullOutputPath , rewriteImports ( content , imports ) ) ;
86
+ }
91
87
92
- this . stubs . set ( fullInputPath , imports ) ;
88
+ this . stubs . set ( fullInputPath , imports ) ;
93
89
94
- break ;
95
- }
90
+ break ;
91
+ }
96
92
} , this ) ;
97
93
98
94
debug ( 'patched applied in: %dms' , Date . now ( ) - applyPatch ) ;
You can’t perform that action at this time.
0 commit comments