public IHttpActionResult DeleteTask(string id) { TaskBusiness tb = new TaskBusiness(); var isDeleted = tb.DeleteTask(id); return(Ok(isDeleted)); }
public IHttpActionResult DeleteTask(int id) { Task task = taskBusiness.GetTask(id); if (task == null) { return(NotFound()); } taskBusiness.DeleteTask(task); return(Ok(task)); }