summaryrefslogtreecommitdiffstats
path: root/api
diff options
context:
space:
mode:
Diffstat (limited to 'api')
-rw-r--r--api/admin.go2
-rw-r--r--api/templates/email_change_body.html2
-rw-r--r--api/user.go6
3 files changed, 6 insertions, 4 deletions
diff --git a/api/admin.go b/api/admin.go
index e8cb8b3c7..5a645dc97 100644
--- a/api/admin.go
+++ b/api/admin.go
@@ -120,6 +120,8 @@ func getConfig(c *Context, w http.ResponseWriter, r *http.Request) {
cfg := model.ConfigFromJson(strings.NewReader(json))
json = cfg.ToJson()
+ w.Header().Set("Cache-Control", "no-cache, no-store, must-revalidate")
+ w.Header().Set("Expires", "0")
w.Write([]byte(json))
}
diff --git a/api/templates/email_change_body.html b/api/templates/email_change_body.html
index 4f28584c4..41b1bcd7d 100644
--- a/api/templates/email_change_body.html
+++ b/api/templates/email_change_body.html
@@ -18,7 +18,7 @@
<tr>
<td style="border-bottom: 1px solid #ddd; padding: 0 0 20px;">
<h2 style="font-weight: normal; margin-top: 10px;">{{.Props.Title}}</h2>
- <p>{{.Props.Info}}</p>
+ <p>{{.Html.Info}}</p>
</td>
</tr>
<tr>
diff --git a/api/user.go b/api/user.go
index 8f381aeda..db8de5f6a 100644
--- a/api/user.go
+++ b/api/user.go
@@ -1761,14 +1761,14 @@ func sendEmailChangeEmailAndForget(c *Context, oldEmail, newEmail, teamDisplayNa
go func() {
subjectPage := NewServerTemplatePage("email_change_subject", c.Locale)
- subjectPage.Props["Subject"] = c.T("api.templates.email_change_body",
+ subjectPage.Props["Subject"] = c.T("api.templates.email_change_subject",
map[string]interface{}{"TeamDisplayName": teamDisplayName})
bodyPage := NewServerTemplatePage("email_change_body", c.Locale)
bodyPage.Props["SiteURL"] = siteURL
bodyPage.Props["Title"] = c.T("api.templates.email_change_body.title")
- bodyPage.Props["Info"] = c.T("api.templates.email_change_body.info",
- map[string]interface{}{"TeamDisplayName": teamDisplayName, "NewEmail": newEmail})
+ bodyPage.Html["Info"] = template.HTML(c.T("api.templates.email_change_body.info",
+ map[string]interface{}{"TeamDisplayName": teamDisplayName, "NewEmail": newEmail}))
if err := utils.SendMail(oldEmail, subjectPage.Render(), bodyPage.Render()); err != nil {
l4g.Error(utils.T("api.user.send_email_change_email_and_forget.error"), err)