C
C#2y ago
Kosta

Why cant i go into the methode? Seems to skip it entirely

Added a git, anybody got and idea?
12 Replies
ero
ero2y ago
because it's async and you're not awaiting it i guess
Kosta
KostaOP2y ago
app.MapGet("/test", async () =>
{
await MakeHttpCall();
});
app.MapGet("/test", async () =>
{
await MakeHttpCall();
});
this code results in an error build
Wz
Wz2y ago
It’s an enumerable, it does nothing until something enumerates it
Kosta
KostaOP2y ago
@Wz can u elaborate?
Wz
Wz2y ago
You need to await foreach to iterate the enumerable Or return it to something that will do so
Kosta
KostaOP2y ago
hm i dont quite get you i got no foreachloop
Servator
Servator2y ago
Instead of returning get values when it can It calculates all values then returns it
Kosta
KostaOP2y ago
So How would u write it?
Servator
Servator2y ago
Also it shouldn't take that time You are doing something wrong i guess How many lines has that .csv file ?
Kosta
KostaOP2y ago
lol i did return MakeHttpCall and it works now XD 5 million
Servator
Servator2y ago
oh
Kosta
KostaOP2y ago
guess you gotta return that
Want results from more Discord servers?
Add your server