I am calling a method in Web API(C#) from repository. The method is repository is not returning anything. It is Void. whay should I return in my API method as a async method cannot have a Void return type.
This is my Async method in API:
[HttpPost]
[Route("AddApp")]
public async Task<?> AddApp([FromBody]Application app)
{
loansRepository.InsertApplication(app);
}
and this is EntityFrame work Insert in repository(I can cot change this by the way)
public void InsertApplication(Application app)
{
this.loansContext.Application.Add(app);
}
Sorry I made changes to the question, I am not sure what should I have for ? in the Task