Skip to content

Commit d1c4a48

Browse files
authored
no-nested-ternary: Fix typo in message (#2705)
1 parent 2a8e152 commit d1c4a48

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

rules/no-nested-ternary.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ const MESSAGE_ID_TOO_DEEP = 'too-deep';
44
const MESSAGE_ID_SHOULD_PARENTHESIZED = 'should-parenthesized';
55
const messages = {
66
[MESSAGE_ID_TOO_DEEP]: 'Do not nest ternary expressions.',
7-
[MESSAGE_ID_SHOULD_PARENTHESIZED]: 'Nest ternary expression should be parenthesized.',
7+
[MESSAGE_ID_SHOULD_PARENTHESIZED]: 'Nested ternary expression should be parenthesized.',
88
};
99

1010
/** @param {import('eslint').Rule.RuleContext} context */

test/snapshots/no-nested-ternary.js.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,14 +22,14 @@ Generated by [AVA](https://avajs.dev).
2222
2323
`␊
2424
> 1 | const foo = i > 5 ? i < 100 ? true : false : i < 100 ? true : false;␊
25-
| ^^^^^^^^^^^^^^^^^^^^^^ Nest ternary expression should be parenthesized.␊
25+
| ^^^^^^^^^^^^^^^^^^^^^^ Nested ternary expression should be parenthesized.␊
2626
`
2727

2828
> Error 2/2
2929
3030
`␊
3131
> 1 | const foo = i > 5 ? i < 100 ? true : false : i < 100 ? true : false;␊
32-
| ^^^^^^^^^^^^^^^^^^^^^^ Nest ternary expression should be parenthesized.␊
32+
| ^^^^^^^^^^^^^^^^^^^^^^ Nested ternary expression should be parenthesized.␊
3333
`
3434

3535
## invalid(2): const foo = i > 5 ? true : (i < 100 ? true : (i < 1000 ? true : false));
4 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)