diff --git a/src/LinkDotNet.Blog.Domain/BlogPost.cs b/src/LinkDotNet.Blog.Domain/BlogPost.cs index 9dbfd07e..cb3866d2 100644 --- a/src/LinkDotNet.Blog.Domain/BlogPost.cs +++ b/src/LinkDotNet.Blog.Domain/BlogPost.cs @@ -4,7 +4,7 @@ namespace LinkDotNet.Blog.Domain; -public class BlogPost : Entity +public sealed class BlogPost : Entity { private BlogPost() { @@ -24,7 +24,7 @@ private BlogPost() public DateTime? ScheduledPublishDate { get; private set; } - public virtual ICollection Tags { get; private set; } + public ICollection Tags { get; private set; } public bool IsPublished { get; private set; } diff --git a/src/LinkDotNet.Blog.Domain/Introduction.cs b/src/LinkDotNet.Blog.Domain/Introduction.cs index d7664415..d1c5e06c 100644 --- a/src/LinkDotNet.Blog.Domain/Introduction.cs +++ b/src/LinkDotNet.Blog.Domain/Introduction.cs @@ -1,6 +1,6 @@ namespace LinkDotNet.Blog.Domain; -public record Introduction +public sealed record Introduction { public string BackgroundUrl { get; init; } diff --git a/src/LinkDotNet.Blog.Domain/ProficiencyLevel.cs b/src/LinkDotNet.Blog.Domain/ProficiencyLevel.cs index b1dcdeea..f5933949 100644 --- a/src/LinkDotNet.Blog.Domain/ProficiencyLevel.cs +++ b/src/LinkDotNet.Blog.Domain/ProficiencyLevel.cs @@ -1,6 +1,6 @@ namespace LinkDotNet.Blog.Domain; -public class ProficiencyLevel : Enumeration +public sealed class ProficiencyLevel : Enumeration { public static readonly ProficiencyLevel Familiar = new(nameof(Familiar)); public static readonly ProficiencyLevel Proficient = new(nameof(Proficient)); diff --git a/src/LinkDotNet.Blog.Domain/ProfileInformation.cs b/src/LinkDotNet.Blog.Domain/ProfileInformation.cs index 6cee9ecc..a084ca74 100644 --- a/src/LinkDotNet.Blog.Domain/ProfileInformation.cs +++ b/src/LinkDotNet.Blog.Domain/ProfileInformation.cs @@ -1,6 +1,6 @@ namespace LinkDotNet.Blog.Domain; -public record ProfileInformation +public sealed record ProfileInformation { public string Name { get; init; } diff --git a/src/LinkDotNet.Blog.Domain/ProfileInformationEntry.cs b/src/LinkDotNet.Blog.Domain/ProfileInformationEntry.cs index 20b73a89..c4a05c8a 100644 --- a/src/LinkDotNet.Blog.Domain/ProfileInformationEntry.cs +++ b/src/LinkDotNet.Blog.Domain/ProfileInformationEntry.cs @@ -4,7 +4,7 @@ namespace LinkDotNet.Blog.Domain; [DebuggerDisplay("{Content} with sort order {SortOrder}")] -public class ProfileInformationEntry : Entity +public sealed class ProfileInformationEntry : Entity { private ProfileInformationEntry() { diff --git a/src/LinkDotNet.Blog.Domain/Skill.cs b/src/LinkDotNet.Blog.Domain/Skill.cs index 2596d9f6..69cfa392 100644 --- a/src/LinkDotNet.Blog.Domain/Skill.cs +++ b/src/LinkDotNet.Blog.Domain/Skill.cs @@ -2,7 +2,7 @@ namespace LinkDotNet.Blog.Domain; -public class Skill : Entity +public sealed class Skill : Entity { private Skill() { diff --git a/src/LinkDotNet.Blog.Domain/Social.cs b/src/LinkDotNet.Blog.Domain/Social.cs index 0c43fa8a..f843d248 100644 --- a/src/LinkDotNet.Blog.Domain/Social.cs +++ b/src/LinkDotNet.Blog.Domain/Social.cs @@ -1,6 +1,6 @@ namespace LinkDotNet.Blog.Domain; -public record Social +public sealed record Social { public string LinkedinAccountUrl { get; init; } diff --git a/src/LinkDotNet.Blog.Domain/Tag.cs b/src/LinkDotNet.Blog.Domain/Tag.cs index 2573a26b..6ad5f5eb 100644 --- a/src/LinkDotNet.Blog.Domain/Tag.cs +++ b/src/LinkDotNet.Blog.Domain/Tag.cs @@ -2,7 +2,7 @@ namespace LinkDotNet.Blog.Domain; -public class Tag +public sealed class Tag { private Tag() { diff --git a/src/LinkDotNet.Blog.Domain/Talk.cs b/src/LinkDotNet.Blog.Domain/Talk.cs index ad79b722..f8702b04 100644 --- a/src/LinkDotNet.Blog.Domain/Talk.cs +++ b/src/LinkDotNet.Blog.Domain/Talk.cs @@ -2,7 +2,7 @@ namespace LinkDotNet.Blog.Domain; -public class Talk : Entity +public sealed class Talk : Entity { private Talk() { diff --git a/src/LinkDotNet.Blog.Domain/UserRecord.cs b/src/LinkDotNet.Blog.Domain/UserRecord.cs index df6b2dce..e2c1ed9d 100644 --- a/src/LinkDotNet.Blog.Domain/UserRecord.cs +++ b/src/LinkDotNet.Blog.Domain/UserRecord.cs @@ -2,7 +2,7 @@ namespace LinkDotNet.Blog.Domain; -public class UserRecord : Entity +public sealed class UserRecord : Entity { public int UserIdentifierHash { get; set; } diff --git a/src/LinkDotNet.Blog.Infrastructure/Persistence/PersistenceProvider.cs b/src/LinkDotNet.Blog.Infrastructure/Persistence/PersistenceProvider.cs index 6c3e16f4..2c3122aa 100644 --- a/src/LinkDotNet.Blog.Infrastructure/Persistence/PersistenceProvider.cs +++ b/src/LinkDotNet.Blog.Infrastructure/Persistence/PersistenceProvider.cs @@ -2,7 +2,7 @@ namespace LinkDotNet.Blog.Infrastructure.Persistence; -public class PersistenceProvider : Enumeration +public sealed class PersistenceProvider : Enumeration { public static readonly PersistenceProvider SqlServer = new(nameof(SqlServer)); public static readonly PersistenceProvider Sqlite = new(nameof(Sqlite)); @@ -10,7 +10,7 @@ public class PersistenceProvider : Enumeration public static readonly PersistenceProvider InMemory = new(nameof(InMemory)); public static readonly PersistenceProvider MySql = new(nameof(MySql)); - protected PersistenceProvider(string key) + private PersistenceProvider(string key) : base(key) { } diff --git a/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/BlogPostConfiguration.cs b/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/BlogPostConfiguration.cs index 294ea77e..7b9046a2 100644 --- a/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/BlogPostConfiguration.cs +++ b/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/BlogPostConfiguration.cs @@ -4,7 +4,7 @@ namespace LinkDotNet.Blog.Infrastructure.Persistence.Sql.Mapping; -public class BlogPostConfiguration : IEntityTypeConfiguration +public sealed class BlogPostConfiguration : IEntityTypeConfiguration { public void Configure(EntityTypeBuilder builder) { diff --git a/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/ProfileInformationEntryConfiguration.cs b/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/ProfileInformationEntryConfiguration.cs index 1fc75f0b..4cf81b17 100644 --- a/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/ProfileInformationEntryConfiguration.cs +++ b/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/ProfileInformationEntryConfiguration.cs @@ -4,7 +4,7 @@ namespace LinkDotNet.Blog.Infrastructure.Persistence.Sql.Mapping; -public class ProfileInformationEntryConfiguration : IEntityTypeConfiguration +public sealed class ProfileInformationEntryConfiguration : IEntityTypeConfiguration { public void Configure(EntityTypeBuilder builder) { diff --git a/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/SkillConfiguration.cs b/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/SkillConfiguration.cs index 1569135a..6331c67a 100644 --- a/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/SkillConfiguration.cs +++ b/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/SkillConfiguration.cs @@ -4,7 +4,7 @@ namespace LinkDotNet.Blog.Infrastructure.Persistence.Sql.Mapping; -public class SkillConfiguration : IEntityTypeConfiguration +public sealed class SkillConfiguration : IEntityTypeConfiguration { public void Configure(EntityTypeBuilder builder) { diff --git a/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/TagsConfiguration.cs b/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/TagsConfiguration.cs index 38bba97e..09a76f7c 100644 --- a/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/TagsConfiguration.cs +++ b/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/TagsConfiguration.cs @@ -4,7 +4,7 @@ namespace LinkDotNet.Blog.Infrastructure.Persistence.Sql.Mapping; -public class TagsConfiguration : IEntityTypeConfiguration +public sealed class TagsConfiguration : IEntityTypeConfiguration { public void Configure(EntityTypeBuilder builder) { diff --git a/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/TalkConfiguration.cs b/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/TalkConfiguration.cs index ab6283ee..d1c61cea 100644 --- a/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/TalkConfiguration.cs +++ b/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/TalkConfiguration.cs @@ -4,7 +4,7 @@ namespace LinkDotNet.Blog.Infrastructure.Persistence.Sql.Mapping; -public class TalkConfiguration : IEntityTypeConfiguration +public sealed class TalkConfiguration : IEntityTypeConfiguration { public void Configure(EntityTypeBuilder builder) { diff --git a/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/UserRecordConfiguration.cs b/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/UserRecordConfiguration.cs index 382c047b..b4a71334 100644 --- a/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/UserRecordConfiguration.cs +++ b/src/LinkDotNet.Blog.Infrastructure/Persistence/Sql/Mapping/UserRecordConfiguration.cs @@ -4,7 +4,7 @@ namespace LinkDotNet.Blog.Infrastructure.Persistence.Sql.Mapping; -public class UserRecordConfiguration : IEntityTypeConfiguration +public sealed class UserRecordConfiguration : IEntityTypeConfiguration { public void Configure(EntityTypeBuilder builder) { diff --git a/src/LinkDotNet.Blog.Web/AppConfiguration.cs b/src/LinkDotNet.Blog.Web/AppConfiguration.cs index b069b1df..a80ca417 100644 --- a/src/LinkDotNet.Blog.Web/AppConfiguration.cs +++ b/src/LinkDotNet.Blog.Web/AppConfiguration.cs @@ -3,7 +3,7 @@ namespace LinkDotNet.Blog.Web; -public record AppConfiguration +public sealed record AppConfiguration { public string BlogName { get; init; } diff --git a/src/LinkDotNet.Blog.Web/Authentication/Auth0/Auth0Information.cs b/src/LinkDotNet.Blog.Web/Authentication/Auth0/Auth0Information.cs index cc60ee64..30bcb7a3 100644 --- a/src/LinkDotNet.Blog.Web/Authentication/Auth0/Auth0Information.cs +++ b/src/LinkDotNet.Blog.Web/Authentication/Auth0/Auth0Information.cs @@ -1,6 +1,6 @@ namespace LinkDotNet.Blog.Web.Authentication.Auth0; -public record Auth0Information +public sealed record Auth0Information { public string Domain { get; init; } diff --git a/src/LinkDotNet.Blog.Web/Authentication/Auth0/Auth0LoginManager.cs b/src/LinkDotNet.Blog.Web/Authentication/Auth0/Auth0LoginManager.cs index c71f7ff2..df7fb700 100644 --- a/src/LinkDotNet.Blog.Web/Authentication/Auth0/Auth0LoginManager.cs +++ b/src/LinkDotNet.Blog.Web/Authentication/Auth0/Auth0LoginManager.cs @@ -6,7 +6,7 @@ namespace LinkDotNet.Blog.Web.Authentication.Auth0; -public class Auth0LoginManager : ILoginManager +public sealed class Auth0LoginManager : ILoginManager { private readonly HttpContext httpContext; diff --git a/src/LinkDotNet.Blog.Web/Authentication/Dummy/DummyLoginManager.cs b/src/LinkDotNet.Blog.Web/Authentication/Dummy/DummyLoginManager.cs index ddf7007f..e499c888 100644 --- a/src/LinkDotNet.Blog.Web/Authentication/Dummy/DummyLoginManager.cs +++ b/src/LinkDotNet.Blog.Web/Authentication/Dummy/DummyLoginManager.cs @@ -7,7 +7,7 @@ namespace LinkDotNet.Blog.Web.Authentication.Dummy; -public class DummyLoginManager : ILoginManager +public sealed class DummyLoginManager : ILoginManager { private readonly HttpContext context; diff --git a/src/LinkDotNet.Blog.Web/Controller/RssFeedController.cs b/src/LinkDotNet.Blog.Web/Controller/RssFeedController.cs index a39b6c8a..43532e3d 100644 --- a/src/LinkDotNet.Blog.Web/Controller/RssFeedController.cs +++ b/src/LinkDotNet.Blog.Web/Controller/RssFeedController.cs @@ -14,7 +14,7 @@ namespace LinkDotNet.Blog.Web.Controller; -public class RssFeedController : ControllerBase +public sealed class RssFeedController : ControllerBase { private readonly AppConfiguration appConfiguration; private readonly IRepository blogPostRepository; diff --git a/src/LinkDotNet.Blog.Web/Features/AboutMe/Components/Skill/AddSkillModel.cs b/src/LinkDotNet.Blog.Web/Features/AboutMe/Components/Skill/AddSkillModel.cs index 609628f8..f894c4a2 100644 --- a/src/LinkDotNet.Blog.Web/Features/AboutMe/Components/Skill/AddSkillModel.cs +++ b/src/LinkDotNet.Blog.Web/Features/AboutMe/Components/Skill/AddSkillModel.cs @@ -3,7 +3,7 @@ namespace LinkDotNet.Blog.Web.Features.AboutMe.Components.Skill; -public class AddSkillModel +public sealed class AddSkillModel { [Required] public string Skill { get; set; } diff --git a/src/LinkDotNet.Blog.Web/Features/AboutMe/Components/Talk/AddTalkEntryModel.cs b/src/LinkDotNet.Blog.Web/Features/AboutMe/Components/Talk/AddTalkEntryModel.cs index 7ef89ed5..181bb7fa 100644 --- a/src/LinkDotNet.Blog.Web/Features/AboutMe/Components/Talk/AddTalkEntryModel.cs +++ b/src/LinkDotNet.Blog.Web/Features/AboutMe/Components/Talk/AddTalkEntryModel.cs @@ -3,7 +3,7 @@ namespace LinkDotNet.Blog.Web.Features.AboutMe.Components.Talk; -public class AddTalkEntryModel +public sealed class AddTalkEntryModel { [Required] [MaxLength(256)] diff --git a/src/LinkDotNet.Blog.Web/Features/Admin/BlogPostEditor/Components/CreateNewModel.cs b/src/LinkDotNet.Blog.Web/Features/Admin/BlogPostEditor/Components/CreateNewModel.cs index 8f37e135..213e1579 100644 --- a/src/LinkDotNet.Blog.Web/Features/Admin/BlogPostEditor/Components/CreateNewModel.cs +++ b/src/LinkDotNet.Blog.Web/Features/Admin/BlogPostEditor/Components/CreateNewModel.cs @@ -4,7 +4,7 @@ namespace LinkDotNet.Blog.Web.Features.Admin.BlogPostEditor.Components; -public class CreateNewModel +public sealed class CreateNewModel { private DateTime originalUpdatedDate; private string id; diff --git a/src/LinkDotNet.Blog.Web/Features/Admin/BlogPostEditor/Services/FileProcessor.cs b/src/LinkDotNet.Blog.Web/Features/Admin/BlogPostEditor/Services/FileProcessor.cs index fe2e4704..0e43159f 100644 --- a/src/LinkDotNet.Blog.Web/Features/Admin/BlogPostEditor/Services/FileProcessor.cs +++ b/src/LinkDotNet.Blog.Web/Features/Admin/BlogPostEditor/Services/FileProcessor.cs @@ -4,7 +4,7 @@ namespace LinkDotNet.Blog.Web.Features.Admin.BlogPostEditor.Services; -public class FileProcessor : IFileProcessor +public sealed class FileProcessor : IFileProcessor { public async Task GetContentAsync(IBrowserFile file) { diff --git a/src/LinkDotNet.Blog.Web/Features/Admin/Dashboard/Services/DashboardData.cs b/src/LinkDotNet.Blog.Web/Features/Admin/Dashboard/Services/DashboardData.cs index d37951e6..39e5c31d 100644 --- a/src/LinkDotNet.Blog.Web/Features/Admin/Dashboard/Services/DashboardData.cs +++ b/src/LinkDotNet.Blog.Web/Features/Admin/Dashboard/Services/DashboardData.cs @@ -1,6 +1,6 @@ namespace LinkDotNet.Blog.Web.Features.Admin.Dashboard.Services; -public class DashboardData +public sealed class DashboardData { public int TotalAmountOfUsers { get; init; } diff --git a/src/LinkDotNet.Blog.Web/Features/Admin/Dashboard/Services/DashboardService.cs b/src/LinkDotNet.Blog.Web/Features/Admin/Dashboard/Services/DashboardService.cs index 2bbea4e2..187bfae8 100644 --- a/src/LinkDotNet.Blog.Web/Features/Admin/Dashboard/Services/DashboardService.cs +++ b/src/LinkDotNet.Blog.Web/Features/Admin/Dashboard/Services/DashboardService.cs @@ -6,7 +6,7 @@ namespace LinkDotNet.Blog.Web.Features.Admin.Dashboard.Services; -public class DashboardService : IDashboardService +public sealed class DashboardService : IDashboardService { private readonly IRepository userRecordRepository; diff --git a/src/LinkDotNet.Blog.Web/Features/Admin/Dashboard/Services/VisitCountPageData.cs b/src/LinkDotNet.Blog.Web/Features/Admin/Dashboard/Services/VisitCountPageData.cs index 126532d6..157df40c 100644 --- a/src/LinkDotNet.Blog.Web/Features/Admin/Dashboard/Services/VisitCountPageData.cs +++ b/src/LinkDotNet.Blog.Web/Features/Admin/Dashboard/Services/VisitCountPageData.cs @@ -1,6 +1,6 @@ namespace LinkDotNet.Blog.Web.Features.Admin.Dashboard.Services; -public record VisitCountPageData +public sealed record VisitCountPageData { public string Id { get; init; } 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 5a5779fc..10be3635 100644 --- a/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/SitemapService.cs +++ b/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/SitemapService.cs @@ -9,7 +9,7 @@ namespace LinkDotNet.Blog.Web.Features.Admin.Sitemap.Services; -public class SitemapService : ISitemapService +public sealed class SitemapService : ISitemapService { private readonly IRepository repository; private readonly NavigationManager navigationManager; diff --git a/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/SitemapUrl.cs b/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/SitemapUrl.cs index b1f3d67e..540e2d26 100644 --- a/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/SitemapUrl.cs +++ b/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/SitemapUrl.cs @@ -3,7 +3,7 @@ namespace LinkDotNet.Blog.Web.Features.Admin.Sitemap.Services; [XmlRoot(ElementName = "url")] -public class SitemapUrl +public sealed class SitemapUrl { [XmlElement(ElementName = "loc")] public string Location { get; set; } diff --git a/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/SitemapUrlSet.cs b/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/SitemapUrlSet.cs index a182cf5e..8f5c8429 100644 --- a/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/SitemapUrlSet.cs +++ b/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/SitemapUrlSet.cs @@ -4,7 +4,7 @@ namespace LinkDotNet.Blog.Web.Features.Admin.Sitemap.Services; [XmlRoot(ElementName = "urlset", Namespace = "http://www.sitemaps.org/schemas/sitemap/0.9")] -public class SitemapUrlSet +public sealed class SitemapUrlSet { [XmlElement(ElementName = "url")] public List Urls { get; set; } = new(); diff --git a/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/XmlFileWriter.cs b/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/XmlFileWriter.cs index 87af8a19..7dd7bb42 100644 --- a/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/XmlFileWriter.cs +++ b/src/LinkDotNet.Blog.Web/Features/Admin/Sitemap/Services/XmlFileWriter.cs @@ -5,7 +5,7 @@ namespace LinkDotNet.Blog.Web.Features.Admin.Sitemap.Services; -public class XmlFileWriter : IXmlFileWriter +public sealed class XmlFileWriter : IXmlFileWriter { public async Task WriteObjectToXmlFileAsync(T objectToSave, string fileName) { diff --git a/src/LinkDotNet.Blog.Web/Features/BlogPostPublisher.cs b/src/LinkDotNet.Blog.Web/Features/BlogPostPublisher.cs index bc82be29..baf66663 100644 --- a/src/LinkDotNet.Blog.Web/Features/BlogPostPublisher.cs +++ b/src/LinkDotNet.Blog.Web/Features/BlogPostPublisher.cs @@ -12,7 +12,7 @@ namespace LinkDotNet.Blog.Web.Features; -public class BlogPostPublisher : BackgroundService +public sealed class BlogPostPublisher : BackgroundService { private readonly IServiceProvider serviceProvider; private readonly ILogger logger; diff --git a/src/LinkDotNet.Blog.Web/Features/Services/LocalStorageService.cs b/src/LinkDotNet.Blog.Web/Features/Services/LocalStorageService.cs index 45a0c90d..ab917ef2 100644 --- a/src/LinkDotNet.Blog.Web/Features/Services/LocalStorageService.cs +++ b/src/LinkDotNet.Blog.Web/Features/Services/LocalStorageService.cs @@ -3,7 +3,7 @@ namespace LinkDotNet.Blog.Web.Features.Services; -public class LocalStorageService : ILocalStorageService +public sealed class LocalStorageService : ILocalStorageService { private readonly ProtectedLocalStorage localStorage; diff --git a/src/LinkDotNet.Blog.Web/Features/Services/SortOrderCalculator.cs b/src/LinkDotNet.Blog.Web/Features/Services/SortOrderCalculator.cs index e2da3ecb..03694e1e 100644 --- a/src/LinkDotNet.Blog.Web/Features/Services/SortOrderCalculator.cs +++ b/src/LinkDotNet.Blog.Web/Features/Services/SortOrderCalculator.cs @@ -3,7 +3,7 @@ namespace LinkDotNet.Blog.Web.Features.Services; -public class SortOrderCalculator : ISortOrderCalculator +public sealed class SortOrderCalculator : ISortOrderCalculator { public int GetSortOrder(ProfileInformationEntry target, IEnumerable all) { diff --git a/src/LinkDotNet.Blog.Web/Features/Services/UserRecordService.cs b/src/LinkDotNet.Blog.Web/Features/Services/UserRecordService.cs index ba30e75c..969aca33 100644 --- a/src/LinkDotNet.Blog.Web/Features/Services/UserRecordService.cs +++ b/src/LinkDotNet.Blog.Web/Features/Services/UserRecordService.cs @@ -8,7 +8,7 @@ namespace LinkDotNet.Blog.Web.Features.Services; -public class UserRecordService : IUserRecordService +public sealed class UserRecordService : IUserRecordService { private readonly IRepository userRecordRepository; private readonly NavigationManager navigationManager; diff --git a/src/LinkDotNet.Blog.Web/Features/ShowBlogPost/Components/DisqusConfiguration.cs b/src/LinkDotNet.Blog.Web/Features/ShowBlogPost/Components/DisqusConfiguration.cs index b2232e8e..18cf1072 100644 --- a/src/LinkDotNet.Blog.Web/Features/ShowBlogPost/Components/DisqusConfiguration.cs +++ b/src/LinkDotNet.Blog.Web/Features/ShowBlogPost/Components/DisqusConfiguration.cs @@ -1,6 +1,6 @@ namespace LinkDotNet.Blog.Web.Features.ShowBlogPost.Components; -public record DisqusConfiguration +public sealed record DisqusConfiguration { public string Shortname { get; init; } } \ No newline at end of file diff --git a/src/LinkDotNet.Blog.Web/Features/ShowBlogPost/Components/GiscusConfiguration.cs b/src/LinkDotNet.Blog.Web/Features/ShowBlogPost/Components/GiscusConfiguration.cs index 743feb88..4bdc6367 100644 --- a/src/LinkDotNet.Blog.Web/Features/ShowBlogPost/Components/GiscusConfiguration.cs +++ b/src/LinkDotNet.Blog.Web/Features/ShowBlogPost/Components/GiscusConfiguration.cs @@ -1,6 +1,6 @@ namespace LinkDotNet.Blog.Web.Features.ShowBlogPost.Components; -public record GiscusConfiguration +public sealed record GiscusConfiguration { public string Repository { get; init; } diff --git a/src/LinkDotNet.Blog.Web/Pages/Error.cshtml.cs b/src/LinkDotNet.Blog.Web/Pages/Error.cshtml.cs index 66e274a8..f4519ce1 100644 --- a/src/LinkDotNet.Blog.Web/Pages/Error.cshtml.cs +++ b/src/LinkDotNet.Blog.Web/Pages/Error.cshtml.cs @@ -6,7 +6,7 @@ namespace LinkDotNet.Blog.Web.Pages; [ResponseCache(Duration = 0, Location = ResponseCacheLocation.None, NoStore = true)] [IgnoreAntiforgeryToken] -public partial class ErrorModel : PageModel +public sealed partial class ErrorModel : PageModel { public string RequestId { get; set; } diff --git a/src/LinkDotNet.Blog.Web/Pages/Login.cshtml.cs b/src/LinkDotNet.Blog.Web/Pages/Login.cshtml.cs index d2b6b2ca..5b0f520b 100644 --- a/src/LinkDotNet.Blog.Web/Pages/Login.cshtml.cs +++ b/src/LinkDotNet.Blog.Web/Pages/Login.cshtml.cs @@ -4,7 +4,7 @@ namespace LinkDotNet.Blog.Web.Pages; -public partial class LoginModel : PageModel +public sealed partial class LoginModel : PageModel { private readonly ILoginManager loginManager; diff --git a/src/LinkDotNet.Blog.Web/Pages/Logout.cshtml.cs b/src/LinkDotNet.Blog.Web/Pages/Logout.cshtml.cs index e8038f48..fd835d93 100644 --- a/src/LinkDotNet.Blog.Web/Pages/Logout.cshtml.cs +++ b/src/LinkDotNet.Blog.Web/Pages/Logout.cshtml.cs @@ -4,7 +4,7 @@ namespace LinkDotNet.Blog.Web.Pages; -public partial class LogoutModel : PageModel +public sealed partial class LogoutModel : PageModel { private readonly ILoginManager loginManager; diff --git a/tests/LinkDotNet.Blog.IntegrationTests/Web/Features/Admin/Dashboard/Components/VisitCountPerPageTests.cs b/tests/LinkDotNet.Blog.IntegrationTests/Web/Features/Admin/Dashboard/Components/VisitCountPerPageTests.cs index 0ffbf9ed..e0503d5a 100644 --- a/tests/LinkDotNet.Blog.IntegrationTests/Web/Features/Admin/Dashboard/Components/VisitCountPerPageTests.cs +++ b/tests/LinkDotNet.Blog.IntegrationTests/Web/Features/Admin/Dashboard/Components/VisitCountPerPageTests.cs @@ -120,7 +120,7 @@ private async Task SaveBlogPostArticleClicked(string blogPostId, int count) await DbContext.SaveChangesAsync(); } - private class FilterStubComponent : ComponentBase + private sealed class FilterStubComponent : ComponentBase { [Parameter] public EventCallback FilterChanged { get; set; }