You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We probably need to scan the whole codebase for cases like these at some point – IIRC, there are a number of places where we check for "falsy" values instead of undefined or null. I think there is the possibility to make the eslint rules a bit stricter in this regard to help us with that.
As mentioned above, we are not currently verifying that our codebase uses the boolean expressions correctly. As we all know the nullish values can sometimes by tricked and led us to unwanted bugs (as the bugs that the PR above was solving). I tried to enable "@typescript-eslint/strict-boolean-expressions": "error" into our eslint file, but that requires strictNullChecks to be enabled in tsconfig.json. Therefore, I suggest first completing the long standing #758 and then looking back to this issue.
Packages to be fixed:
binding-coap
binding-modbus
browser-bundle
binding-file
binding-mqtt
cli
binding-netconf
core
binding-opcua
examples
binding-websocket
td-tools
binding-http
binding-mbus
The text was updated successfully, but these errors were encountered:
Originally posted by @JKRhb in #1042 (comment)
As mentioned above, we are not currently verifying that our codebase uses the boolean expressions correctly. As we all know the nullish values can sometimes by tricked and led us to unwanted bugs (as the bugs that the PR above was solving). I tried to enable
"@typescript-eslint/strict-boolean-expressions": "error"
into our eslint file, but that requiresstrictNullChecks
to be enabled intsconfig.json
. Therefore, I suggest first completing the long standing #758 and then looking back to this issue.Packages to be fixed:
The text was updated successfully, but these errors were encountered: