diff --git a/src/LinkDotNet.Blog.Web/Features/AboutMe/Components/Skill/SkillTable.razor b/src/LinkDotNet.Blog.Web/Features/AboutMe/Components/Skill/SkillTable.razor
index 346063b6..05e25239 100644
--- a/src/LinkDotNet.Blog.Web/Features/AboutMe/Components/Skill/SkillTable.razor
+++ b/src/LinkDotNet.Blog.Web/Features/AboutMe/Components/Skill/SkillTable.razor
@@ -51,7 +51,7 @@
@if (ShowAdminActions)
{
- You can drag and drop your skills from one proficency to another
+ You can drag and drop your skills from one proficiency to another
}
@code {
diff --git a/src/LinkDotNet.Blog.Web/Features/Admin/Dashboard/Components/VisitCountPerPage.razor b/src/LinkDotNet.Blog.Web/Features/Admin/Dashboard/Components/VisitCountPerPage.razor
index eceeff7f..3b89447f 100644
--- a/src/LinkDotNet.Blog.Web/Features/Admin/Dashboard/Components/VisitCountPerPage.razor
+++ b/src/LinkDotNet.Blog.Web/Features/Admin/Dashboard/Components/VisitCountPerPage.razor
@@ -4,6 +4,7 @@
@using LinkDotNet.Blog.Infrastructure.Persistence
@using LinkDotNet.Blog.Infrastructure.Persistence.Sql
@using LinkDotNet.Blog.Web.Features.Admin.Dashboard.Services
+@using System.Collections.Immutable
@inject IRepository BlogPostRepository
@inject IRepository UserRecordRepository
@@ -51,14 +52,14 @@
@code {
private Filter filter = new();
- private IList visitData;
+ private IReadOnlyCollection visitData;
protected override async Task OnInitializedAsync()
{
visitData = await LoadBlogPostInformationAsync();
}
- private async Task> LoadBlogPostInformationAsync()
+ private async Task> LoadBlogPostInformationAsync()
{
var blogPostsTask = BlogPostRepository.GetAllByProjectionAsync(
s => new { s.Id, s.Title, s.Likes });
@@ -81,7 +82,7 @@
Title = gp.First().bp.Title,
Likes = gp.First().bp.Likes,
ClickCount = gp.Count()
- }).ToList();
+ }).ToImmutableArray();
return visitCountPage;
}
diff --git a/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/SitemapService.cs b/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/SitemapService.cs
index 8737a079..5a5779fc 100644
--- a/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/SitemapService.cs
+++ b/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/SitemapService.cs
@@ -1,5 +1,6 @@
using System;
using System.Collections.Generic;
+using System.Collections.Immutable;
using System.Linq;
using System.Threading.Tasks;
using LinkDotNet.Blog.Domain;
@@ -49,7 +50,7 @@ private IEnumerable CreateUrlsForBlogPosts(IEnumerable blo
{
Location = $"{navigationManager.BaseUri}blogPost/{b.Id}",
LastModified = b.UpdatedDate.ToString("yyyy-MM-dd"),
- }).ToList();
+ }).ToImmutableArray();
}
private IEnumerable CreateUrlsForTags(IEnumerable blogPosts)
diff --git a/src/LinkDotNet.Blog.Web/Features/Archive/ArchivePage.razor b/src/LinkDotNet.Blog.Web/Features/Archive/ArchivePage.razor
index 370becc0..4bc48571 100644
--- a/src/LinkDotNet.Blog.Web/Features/Archive/ArchivePage.razor
+++ b/src/LinkDotNet.Blog.Web/Features/Archive/ArchivePage.razor
@@ -1,6 +1,7 @@
@page "/archive"
@using LinkDotNet.Blog.Infrastructure.Persistence
@using LinkDotNet.Blog.Domain
+@using System.Collections.Immutable
@inject IRepository Repository
@@ -28,7 +29,7 @@
@code {
- private List> blogPostsPerYear;
+ private IReadOnlyCollection> blogPostsPerYear;
private int blogPostCount;
protected override async Task OnInitializedAsync()
@@ -40,7 +41,7 @@
blogPostsPerYear = blogPosts
.GroupBy(r => r.UpdatedDate.Year)
.OrderByDescending(r => r.Key)
- .ToList();
+ .ToImmutableArray();
}
private sealed record BlogPostPerYear(string Id, string Title, DateTime UpdatedDate);