public async Task <TaskHistoryResponseModel> UpdateTaskHistoryById(int id, TaskHistoryRequestModel taskHistoryRequestModel)
        {
            var taskHistory = new TaskHistory()
            {
                TaskId      = id,
                UserId      = taskHistoryRequestModel.UserId,
                Title       = taskHistoryRequestModel.Title,
                Description = taskHistoryRequestModel.Description,
                DueDate     = taskHistoryRequestModel.DueDate,
                Completed   = taskHistoryRequestModel.Completed,
                Remarks     = taskHistoryRequestModel.Remarks,
            };
            var createdTaskHistory = await _taskHistoryRepository.UpdateAsync(taskHistory);

            var taskHistoryResponse = new TaskHistoryResponseModel()
            {
                TaskId      = createdTaskHistory.TaskId,
                UserId      = createdTaskHistory.UserId,
                Title       = createdTaskHistory.Title,
                Description = createdTaskHistory.Description,
                DueDate     = createdTaskHistory.DueDate,
                Completed   = createdTaskHistory.Completed,
                Remarks     = createdTaskHistory.Remarks,
            };

            return(taskHistoryResponse);
        }
        public async Task <TaskHistory> UpdateTaskHistory(TaskHistoryRequestModel taskHistoryRequest)
        {
            var thDb = await _taskHistoryRepository.GetByIdAsync(taskHistoryRequest.TaskId);

            thDb.UserId      = taskHistoryRequest.UserId;
            thDb.Title       = taskHistoryRequest.Title;
            thDb.Description = taskHistoryRequest.Description;
            thDb.DueDate     = taskHistoryRequest.DueDate;
            thDb.Completed   = taskHistoryRequest.Completed;
            thDb.Remarks     = taskHistoryRequest.Remarks;
            return(await _taskHistoryRepository.UpdateAsync(thDb));
        }