Closed JKRhb closed 2 years ago
Changes Missing Coverage | Covered Lines | Changed/Added Lines | % | ||
---|---|---|---|---|---|
lib/agent.js | 24 | 25 | 96.0% | ||
<!-- | Total: | 44 | 45 | 97.78% | --> |
Totals | |
---|---|
Change from base Build 1313580033: | -0.1% |
Covered Lines: | 1078 |
Relevant Lines: | 1163 |
honestly I do not like "type-unsafe" checks with == or != ... They are not rteally better then the "falsy" checks before ... (in my eyes) but all good we can leave it that way too ...
Yeah, it adds some noise that isn't really necessary :/ The reason for PRs like these were the fact that I activated the option for strict null checks in #293 which complained about checks for falsy values. Maybe we can discuss over there if this is actually necessary. So far I thought the stricter the checks the better but in most cases it probably doesn't bring that much value.
I personally use "falsy" checks if I know that it can not be false and want to do tese checks ... or I really check for types or such depending on what I want/need... but as said ... personal flavour
Another rather trivial PR adding explicit checks for
null
orundefined
.