Skip to content

Commit

Permalink
IDE0305 collection initialization can be simplified
Browse files Browse the repository at this point in the history
  • Loading branch information
davidnmbond committed Jan 3, 2025
1 parent 7d985e2 commit 623135d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion PanoramicData.Blazor.Demo/Pages/PDTablePage.razor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ protected override async Task OnInitializedAsync()
{
// determine unique birth years
var years = await _personDataProvider.GetDistinctValuesAsync(new(), x => x.Dob!.Value.Year);
_ages = years.Select(x => (DateTime.Now.Date.Year - Convert.ToInt32(x)) as object).OrderBy(x => x).ToArray();
_ages = [.. years.Select(x => (DateTime.Now.Date.Year - Convert.ToInt32(x)) as object).OrderBy(x => x)];
}

private async Task SearchAsync()
Expand Down

0 comments on commit 623135d

Please sign in to comment.