AspNetCoreOData
AspNetCoreOData copied to clipboard
IAsyncEnumerable not queryable
When I use the IAsyncEnumerable with a $filter query. Then I get the error that I can't use $filter on a single item but it is on multiple items
[EnableQuery]
public IasyncEnumerable<Test> GetTests() {
Foreach(var item in new List<Test>().AsQueryable()) {
yield return item;
}
}
When using IAsyncEnumerable, you use an await foreach to enumerate it. Also, AsQueryable() will return an IQueryable that does not implement the IAsyncEnumerable. You should instead use AsAsyncEnumerable(). This seems to be a bug though.