File tree Expand file tree Collapse file tree 1 file changed +4
-7
lines changed Expand file tree Collapse file tree 1 file changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -50,21 +50,18 @@ const create = context => {
50
50
51
51
const nodeScope = sourceCode . getScope ( node ) ;
52
52
53
- for ( const ref of nodeScope . through ) {
54
- const { identifier} = ref ;
53
+ for ( const reference of nodeScope . through ) {
54
+ const { identifier} = reference ;
55
55
56
56
if ( allowedGlobals . includes ( identifier . name ) ) {
57
57
continue ;
58
58
}
59
59
60
- // If (!options.considerTypeOf && hasTypeOfOperator(identifier)) {
61
- // return;
62
- // }
60
+ // Could consider checking for typeof operator here, like in no-undef?
63
61
64
62
context . report ( {
65
63
node : identifier ,
66
64
messageId : MESSAGE_ID_EXTERNALLY_SCOPED_VARIABLE ,
67
- // Message: `Variable ${identifier.name} is used from outside the scope of an isolated function. Function is isolated because: ${reason}.`,
68
65
data : { name : identifier . name , reason} ,
69
66
} ) ;
70
67
}
@@ -108,7 +105,7 @@ const create = context => {
108
105
}
109
106
}
110
107
111
- return undefined ;
108
+
112
109
} ;
113
110
114
111
return Object . fromEntries ( functionTypes . map ( type => [
You can’t perform that action at this time.
0 commit comments