public GetGeneralResponse <ToDoView> GetToDo(Guid ToDoID) { GetGeneralResponse <ToDoView> response = new GetGeneralResponse <ToDoView>(); try { ToDo toDo = _toDoRepository.FindBy(ToDoID); response.data = toDo.ConvertToToDoView(); response.totalCount = 1; } catch (Exception ex) { response.ErrorMessages.Add(ex.Message); if (ex.InnerException.InnerException != null) { response.ErrorMessages.Add(ex.InnerException.Message); } } return(response); }