From fea28821e36a533db16ef4de6684e0dabe310e96 Mon Sep 17 00:00:00 2001 From: Agniva De Sarker Date: Wed, 22 Jul 2020 09:41:30 +0530 Subject: [PATCH] MM-26052: Translate footer text in invite emails (#14956) * MM-26052: Translate footer text in invite emails We pass the user locale instead of the default locale to translate the footer text too. * Use default server locale --- app/email.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/email.go b/app/email.go index 896b1f737a..c358b79d74 100644 --- a/app/email.go +++ b/app/email.go @@ -350,7 +350,7 @@ func (es *EmailService) SendInviteEmails(team *model.Team, senderName string, se "TeamDisplayName": team.DisplayName, "SiteName": es.srv.Config().TeamSettings.SiteName}) - bodyPage := es.newEmailTemplate("invite_body", model.DEFAULT_LOCALE) + bodyPage := es.newEmailTemplate("invite_body", "") bodyPage.Props["SiteURL"] = siteURL bodyPage.Props["Title"] = utils.T("api.templates.invite_body.title") bodyPage.Html["Info"] = utils.TranslateAsHtml(utils.T, "api.templates.invite_body.info", @@ -411,7 +411,7 @@ func (es *EmailService) sendGuestInviteEmails(team *model.Team, channels []*mode "TeamDisplayName": team.DisplayName, "SiteName": es.srv.Config().TeamSettings.SiteName}) - bodyPage := es.newEmailTemplate("invite_body", model.DEFAULT_LOCALE) + bodyPage := es.newEmailTemplate("invite_body", "") bodyPage.Props["SiteURL"] = siteURL bodyPage.Props["Title"] = utils.T("api.templates.invite_body.title") bodyPage.Html["Info"] = utils.TranslateAsHtml(utils.T, "api.templates.invite_body_guest.info",