LGTM.com - false positive - [cs/dereferenced-value-may-be-null]
Đang mở
C#
false-positive
- Ngôn ngữ chính
- CodeQL
- Star
- 10.1k
- Fork
- 2.1k
- Merge trung bình
- 2 ngày 15 giờ
- Pull request đã merge (30 ngày)
- 141
Mô tả
**Description of the false positive**
Alert does not consider the order of events in the LINQ query; the value cannot be null.
**URL to the alert on the project page on LGTM.com**
https://lgtm.com/projects/g/DaveSkender/Stock.Indicators/snapshot/71ad67e9bc0c1c073362dc811972e76e48d98902/files/src/a-d/Dpo/Dpo.Utilities.cs?sort=name&dir=ASC&mode=heatmap#x73013381c2ffa1bb:1
```csharp
return results
.Where(x => x.Dpo != null)
.Select(x => new Quote
{
Date = x.Date,
Open = (decimal)x.Dpo,
High = (decimal)x.Dpo,
Low = (decimal)x.Dpo,
Close = (decimal)x.Dpo,
Volume = (decimal)x.Dpo
})
.ToList();
```
Hướng dẫn đóng góp
Đánh giá
Issue này chưa được đánh giá.