Skip to content

Commit

Permalink
micro-optimization
Browse files Browse the repository at this point in the history
  • Loading branch information
Edward Miller committed Mar 28, 2024
1 parent 9e91dbc commit db5dcbd
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Maui.DataGrid/DataGridRow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,9 @@ private View CreateEditCell(DataGridColumn col)

private View CreateDefaultEditCell(DataGridColumn col)
{
return Type.GetTypeCode(col.DataType) switch
var typeCode = Type.GetTypeCode(col.DataType);

return typeCode switch
{
TypeCode.String => GenerateTextEditCell(col),
TypeCode.Boolean => GenerateBooleanEditCell(col),
Expand Down

0 comments on commit db5dcbd

Please sign in to comment.