From 799f507dce2f41b76990cc568410704a22c54837 Mon Sep 17 00:00:00 2001 From: Claire Date: Fri, 11 Oct 2024 12:24:03 +0200 Subject: [PATCH] Fix language of push notifications (#32415) --- app/workers/web/push_notification_worker.rb | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/app/workers/web/push_notification_worker.rb b/app/workers/web/push_notification_worker.rb index 104503f13..e771928ef 100644 --- a/app/workers/web/push_notification_worker.rb +++ b/app/workers/web/push_notification_worker.rb @@ -55,12 +55,8 @@ class Web::PushNotificationWorker end def push_notification_json - Oj.dump(serialized_notification_in_subscription_locale.as_json) - end - - def serialized_notification_in_subscription_locale I18n.with_locale(@subscription.locale.presence || I18n.default_locale) do - serialized_notification + Oj.dump(serialized_notification.as_json) end end