private void ItemStatusChanged(object sender, EventArgs e) { if (sender is ToDoItemViewModel item) { if (!ShowAll && item.Item.Completed) { Items.Remove(item); } Task.Run(async() => await repository.UpdateItem(item.Item)); } }
private void ItemStatusChanged(object sender, EventArgs e) { if (sender is ToDoItemViewModel item) { if (!ShowAll && item.Item.Completed) { Items.Remove(item); } Task.Run(async() => await repository.UpdateItem(item.Item)); } }