Skip to content

Commit

Permalink
ignore string case when removing columns in sample
Browse files Browse the repository at this point in the history
  • Loading branch information
Edward Miller committed Jan 24, 2024
1 parent 2d5ae2b commit 5698929
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Maui.DataGrid.Sample/SettingsPopup.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ private async void OnRemoveColumn(object sender, EventArgs e)
{
var columnTitle = await Shell.Current.DisplayPromptAsync("Remove column", "Which column should be removed?");

var columnToRemove = _viewModel.Columns.FirstOrDefault(c => c.Title == columnTitle);
var columnToRemove = _viewModel.Columns.FirstOrDefault(c => c.Title.Equals(columnTitle, StringComparison.OrdinalIgnoreCase));

if (columnToRemove == null)
{
Expand Down

0 comments on commit 5698929

Please sign in to comment.