Example #1
0
        public async Task <IActionResult> DeleteTodoItem(long id)
        {
            var todoItem = await _itemRepository.GetItemByIdAsync(id);

            if (todoItem == null)
            {
                return(NotFound());
            }

            await _itemRepository.DeleteItemAsync(todoItem);

            return(NoContent());
        }