Skip to content

Commit

Permalink
#792 Minor resource name fix for SQLite
Browse files Browse the repository at this point in the history
  • Loading branch information
mgesing committed Sep 4, 2023
1 parent faba59b commit 643bdf5
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/Smartstore.Core/Migrations/SmartDbContextDataSeeder.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
using Smartstore.Core.Checkout.Payment;
using Smartstore.Core.Configuration;
using Smartstore.Core.DataExchange.Import;
using Smartstore.Core.Identity;
using Smartstore.Data.Migrations;

namespace Smartstore.Core.Data.Migrations
Expand All @@ -12,6 +10,12 @@ public class SmartDbContextDataSeeder : IDataSeeder<SmartDbContext>

public async Task SeedAsync(SmartDbContext context, CancellationToken cancelToken = default)
{
await context.MigrateLocaleResourcesAsync(builder =>
{
// Lower case resource name fix for SQLite. Added resource in pascal case in MigrateLocaleResources below.
builder.Delete("admin.system.systeminfo.appversion", "admin.system.systeminfo.appversion.hint");
});

await context.MigrateLocaleResourcesAsync(MigrateLocaleResources);
await MigrateSettingsAsync(context, cancelToken);
}
Expand Down Expand Up @@ -217,6 +221,8 @@ public void MigrateLocaleResources(LocaleResourcesBuilder builder)

builder.Delete("Enums.CookieConsentRequirement.Disabled");
builder.AddOrUpdate("Enums.CookieConsentRequirement.NeverRequired", "Never required", "Nie erforderlich");

builder.AddOrUpdate("Admin.System.SystemInfo.AppVersion", "Smartstore version", "Smartstore Version");
}

/// <summary>
Expand Down

0 comments on commit 643bdf5

Please sign in to comment.