♻️ Replaced the SetCultureInfo with the new localization engine

This commit is contained in:
2026-02-05 16:28:31 +08:00
parent 3c6ccba74f
commit 0051740cb0
10 changed files with 60 additions and 106 deletions

View File

@@ -114,11 +114,10 @@ public class PublisherSubscriptionService(
{
try
{
CultureService.SetCultureInfo(target.Key);
var notification = new PushNotification
{
Topic = "posts.new",
Title = localizer.Get("postSubscriptionTitle", args: new { publisher = post.Publisher!.Nick, title }),
Title = localizer.Get("postSubscriptionTitle", locale: target.Key, args: new { publisher = post.Publisher!.Nick, title }),
Body = message,
Meta = GrpcTypeHelper.ConvertObjectToByteString(data),
IsSavable = true,
@@ -215,4 +214,4 @@ public class PublisherSubscriptionService(
return true;
}
}
}