Skip to content

Commit 92d3075

Browse files
committed
chore: fix JavaScript lint errors
Move onDrain out of onCommand in end.js so it sits at the same scope as onCommand, matching the convention already used by next.js, prev.js, last.js, jump.js, and friends. Resolves the stdlib/no-unnecessary-nested-functions lint error reported by the automated workflow. Closes: #11803
1 parent 19216fd commit 92d3075

1 file changed

Lines changed: 8 additions & 8 deletions

File tree

  • lib/node_modules/@stdlib/repl/presentation/lib/commands

lib/node_modules/@stdlib/repl/presentation/lib/commands/end.js

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -37,15 +37,15 @@ function command( pres ) {
3737
*/
3838
function onCommand() {
3939
pres._repl.once( 'drain', onDrain ); // eslint-disable-line no-underscore-dangle
40+
}
4041

41-
/**
42-
* Callback invoked upon a `drain` event.
43-
*
44-
* @private
45-
*/
46-
function onDrain() {
47-
pres.end().show();
48-
}
42+
/**
43+
* Callback invoked upon a `drain` event.
44+
*
45+
* @private
46+
*/
47+
function onDrain() {
48+
pres.end().show();
4949
}
5050
}
5151

0 commit comments

Comments
 (0)