Skip to content

Commit c0c2db9

Browse files
committed
Add ignoreRhs option for no-unnecessary-condition rule
Fixes #17
1 parent fd10295 commit c0c2db9

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

index.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,12 @@ module.exports = {
222222
allowDestructuring: true
223223
}
224224
],
225-
'@typescript-eslint/no-unnecessary-condition': 'error',
225+
'@typescript-eslint/no-unnecessary-condition': [
226+
'error',
227+
{
228+
ignoreRhs: true
229+
}
230+
],
226231
'@typescript-eslint/no-unnecessary-qualifier': 'error',
227232
'@typescript-eslint/no-unnecessary-type-arguments': 'error',
228233
'@typescript-eslint/no-unnecessary-type-assertion': 'error',

0 commit comments

Comments
 (0)