Skip to content

Commit 29fd9eb

Browse files
authored
Update main.js
Signed-off-by: VEER RAJ <[email protected]>
1 parent 4b46a3a commit 29fd9eb

File tree

1 file changed

+2
-5
lines changed
  • lib/node_modules/@stdlib/utils/async/if-then/lib

1 file changed

+2
-5
lines changed

lib/node_modules/@stdlib/utils/async/if-then/lib/main.js

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -113,17 +113,14 @@ function ifthenAsync( predicate, x, y, done ) {
113113
*/
114114
function clbk2( error ) {
115115
var nargs;
116-
var args;
117116
var i;
118117
if ( error ) {
119118
return done( error );
120119
}
121120
nargs = arguments.length;
122-
const args = [];
123-
args.length = nargs;
124-
args[ 0 ] = null;
121+
const args = [null];
125122
for ( i = 1; i < nargs; i++ ) {
126-
args[ i ] = arguments[ i ];
123+
args.push(arguments[ i ]);
127124
}
128125
done.apply( null, args );
129126
}

0 commit comments

Comments
 (0)