Inline if ignores object types
Open
- Dominant language
- Rust
- Stars
- 22.3k
- Forks
- 1.9k
- PR merge metrics
- No merged PRs in 30d
Description
This will throw the expected error "property `responseCodeARGH`. Property not found in"
```
const isNotFound = res.apiActionResults[0].responseCodeARGH === 333;
return isNotFound ? [] : res.body.order_ids.split(',');
```
This will not:
```
return res.apiActionResults[0].responseCodeARGH === 333 ? [] : res.body.order_ids.split(',');
```
The only difference logically here is a variable substitution.
Contributor guide
Assessment
This issue has not been assessed yet.