I was asked to update the API and implement the RemoveToDoItem
from the following code:
[HttpDelete("{id}", Name = "DeleteTodoItem")]
public async Task<IActionResult> RemoveTodoItem(int id)
{
// TODO
// Use EF Core to remove the item based on id
throw new NotImplementedException();
}
This is the error code I get when I attempt to run the program
HttpRequestException: you must first implement the API endpoint. Candidate.Web.Services.CandidateApi.RemoveTodoItem(int id) in CandidateApi.cs
}
catch (Exception ex)
{
throw new HttpRequestException("You must first implement the API endpoint.");
}
throw new HttpRequestException("You must first implement the API endpoint.");
Not entirely sure how to go about this. I've tried to use the DeleteTodoItem
variable but no luck.