❔ .NET 6 GET method returns OK even if there is no such endpoint
I've a .NET 6 Web Application with Blazor wasm front-end.
When I make an HTTP GET request from front-end to back-end, even if the address I specify in the request is mapped to no controller method, the server would still respond with an OK and with the index.html page.
I'd like to have a NOT FOUND answer from the server, instead.
I've tried searching on the web but I had no luck until now
3 Replies
Unknown User•3y ago
Message Not Public
Sign In & Join Server To View
You're right, I had
Removing that line was enough to solve the problem 😅
Thank you very much!
Was this issue resolved? If so, run
/close
- otherwise I will mark this as stale and this post will be archived until there is new activity.