Skip to content

Commit cd5c423

Browse files
committed
chore: minor clean-up
1 parent bf8cd07 commit cd5c423

File tree

5 files changed

+7
-7
lines changed

5 files changed

+7
-7
lines changed

lib/node_modules/@stdlib/_tools/eslint/rules/empty-line-before-comment/lib/main.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ function main( context ) {
9595
for ( i = 0; i < comments.length; i++ ) {
9696
current = comments[ i ];
9797
line = current.loc.start.line;
98-
prevLine = source.lines[ line-2 ];
98+
prevLine = source.lines[ line-2 ] || '';
9999
token = source.getTokenBefore( current );
100100

101101
if ( isObject( token ) ) {

lib/node_modules/@stdlib/_tools/eslint/rules/first-unit-test/lib/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
'use strict';
2020

2121
/**
22-
* ESLint rule to enforce enforce that a test file starts with the expected test.
22+
* ESLint rule to enforce that a test file starts with the expected test.
2323
*
2424
* @module @stdlib/_tools/eslint/rules/first-unit-test
2525
*

lib/node_modules/@stdlib/_tools/eslint/rules/first-unit-test/lib/main.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ function main( context ) {
101101
j = 0;
102102

103103
// Skip over all variable declarations...
104-
while ( body.body[ j ].type === 'VariableDeclaration' ) {
104+
while ( j < body.body.length && body.body[ j ].type === 'VariableDeclaration' ) {
105105
j += 1;
106106
}
107107
first = body.body[ j ];

lib/node_modules/@stdlib/_tools/eslint/rules/new-cap-array/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,13 +85,13 @@ result = linter.verify( code, {
8585
{
8686
'ruleId': 'new-cap-array',
8787
'severity': 2,
88-
'message': '`Array` constructor is invoked without the `new` 'keyword',
88+
'message': '`Array` constructor is invoked without the `new` keyword',
8989
'line': 1,
9090
'column': 11,
9191
'nodeType': 'CallExpression',
9292
'source': 'var arr = Array( 10 );',
9393
'endLine': 1,
94-
'endColumn': 41
94+
'endColumn': 22
9595
}
9696
]
9797
*/

lib/node_modules/@stdlib/_tools/eslint/rules/new-cap-array/examples/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,13 +39,13 @@ console.log( result );
3939
{
4040
'ruleId': 'new-cap-array',
4141
'severity': 2,
42-
'message': '`Array` constructor is invoked without the `new` 'keyword',
42+
'message': '`Array` constructor is invoked without the `new` keyword',
4343
'line': 1,
4444
'column': 11,
4545
'nodeType': 'CallExpression',
4646
'source': 'var arr = Array( 10 );',
4747
'endLine': 1,
48-
'endColumn': 41
48+
'endColumn': 22
4949
}
5050
]
5151
*/

0 commit comments

Comments
 (0)