FIX: Use default locale for flag reasons

This commit is contained in:
Gerhard Schlager
2019-07-12 12:04:16 +02:00
parent c4d1833588
commit 7311eeed39
2 changed files with 12 additions and 2 deletions

View File

@@ -34,7 +34,12 @@ class SpamRule::FlagSockpuppets
end
def flag_sockpuppet_users
message = I18n.t('flag_reason.sockpuppet', ip_address: @post.user.ip_address, base_path: Discourse.base_path)
message = I18n.t(
'flag_reason.sockpuppet',
ip_address: @post.user.ip_address,
base_path: Discourse.base_path,
locale: SiteSetting.default_locale
)
PostActionCreator.create(Discourse.system_user, @post, :spam, message: message)