Skip to content
This repository has been archived by the owner on Mar 25, 2021. It is now read-only.

Commit

Permalink
no-unbound-method: add another exception
Browse files Browse the repository at this point in the history
Reading a property with square brackets, though rare, should be allowed because it won't be effected by an unbound this.
  • Loading branch information
ethanresnick committed Dec 27, 2017
1 parent 771498f commit 2e6a8de
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions test/rules/no-unbound-method/default/test.ts.lint
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ function f(i: I) {
i.m ? 1 : 2;
if (i.m) {}
!i.m;
i.m["length"];
return i.m!;
~~~ [0]
}
Expand Down

0 comments on commit 2e6a8de

Please sign in to comment.