File tree 1 file changed +10
-7
lines changed
1 file changed +10
-7
lines changed Original file line number Diff line number Diff line change @@ -67,19 +67,22 @@ module.exports = function f (b, opts) {
67
67
}
68
68
next ( null , row ) ;
69
69
} , function ( next ) {
70
+ var outputResult ;
71
+
72
+ if ( typeof outputs === 'function' ) {
73
+ outputResult = outputs ( ) ;
74
+ } else outputResult = outputs ;
75
+
70
76
var pipelines = files . reduce ( function ( acc , x , ix ) {
71
77
var pipeline = splicer . obj ( [
72
78
'pack' , [ pack ( packOpts ) ] ,
73
79
'wrap' , [ ]
74
80
] ) ;
75
- if ( typeof outputs === 'function' ) {
76
- pipeline . pipe ( outputs ( x ) )
77
- } else {
78
- if ( ix >= outputs . length ) {
79
- outputs . push . apply ( outputs , moreOutputs ( x ) ) ;
80
- }
81
- if ( outputs [ ix ] ) pipeline . pipe ( outputs [ ix ] ) ;
81
+
82
+ if ( ix >= outputResult . length ) {
83
+ outputResult . push . apply ( outputResult , moreOutputs ( x ) ) ;
82
84
}
85
+ if ( outputResult [ ix ] ) pipeline . pipe ( outputResult [ ix ] ) ;
83
86
84
87
acc [ path . resolve ( cwd , x ) ] = pipeline ;
85
88
return acc ;
You can’t perform that action at this time.
0 commit comments