@@ -39,7 +39,7 @@ type Options = AllowLocalMutationOption &
39
39
IgnoreInterfaceOption &
40
40
IgnorePatternOption & {
41
41
readonly allowMutableReturnType : boolean ;
42
- readonly checkImplicit : boolean ;
42
+ readonly checkForImplicitMutableArrays : boolean ;
43
43
readonly ignoreCollections : boolean ;
44
44
} ;
45
45
@@ -56,7 +56,7 @@ const schema: JSONSchema4 = [
56
56
allowMutableReturnType : {
57
57
type : "boolean" ,
58
58
} ,
59
- checkImplicit : {
59
+ checkForImplicitMutableArrays : {
60
60
type : "boolean" ,
61
61
} ,
62
62
ignoreCollections : {
@@ -70,7 +70,7 @@ const schema: JSONSchema4 = [
70
70
71
71
// The default options for the rule.
72
72
const defaultOptions : Options = {
73
- checkImplicit : false ,
73
+ checkForImplicitMutableArrays : false ,
74
74
ignoreClass : false ,
75
75
ignoreInterface : false ,
76
76
ignoreCollections : false ,
@@ -255,7 +255,7 @@ function checkProperty(
255
255
/**
256
256
* Check if the given TypeReference violates this rule.
257
257
*/
258
- function checkImplicitType (
258
+ function checkForImplicitMutableArray (
259
259
node :
260
260
| TSESTree . ArrowFunctionExpression
261
261
| TSESTree . FunctionDeclaration
@@ -264,7 +264,7 @@ function checkImplicitType(
264
264
context : RuleContext < keyof typeof errorMessages , Options > ,
265
265
options : Options
266
266
) : RuleResult < keyof typeof errorMessages , Options > {
267
- if ( options . checkImplicit ) {
267
+ if ( options . checkForImplicitMutableArrays ) {
268
268
type Declarator = {
269
269
readonly id : TSESTree . Node ;
270
270
readonly init : TSESTree . Node | null ;
@@ -324,17 +324,17 @@ export const rule = createRule<keyof typeof errorMessages, Options>(
324
324
meta ,
325
325
defaultOptions ,
326
326
{
327
- ArrowFunctionExpression : checkImplicitType ,
327
+ ArrowFunctionExpression : checkForImplicitMutableArray ,
328
328
ClassProperty : checkProperty ,
329
- FunctionDeclaration : checkImplicitType ,
330
- FunctionExpression : checkImplicitType ,
329
+ FunctionDeclaration : checkForImplicitMutableArray ,
330
+ FunctionExpression : checkForImplicitMutableArray ,
331
331
TSArrayType : checkArrayOrTupleType ,
332
332
TSIndexSignature : checkProperty ,
333
333
TSParameterProperty : checkProperty ,
334
334
TSPropertySignature : checkProperty ,
335
335
TSTupleType : checkArrayOrTupleType ,
336
336
TSMappedType : checkMappedType ,
337
337
TSTypeReference : checkTypeReference ,
338
- VariableDeclaration : checkImplicitType ,
338
+ VariableDeclaration : checkForImplicitMutableArray ,
339
339
}
340
340
) ;
0 commit comments