diff --git a/pkg/context/context.go b/pkg/context/context.go index 40d7c8c77..4a11ce064 100644 --- a/pkg/context/context.go +++ b/pkg/context/context.go @@ -212,10 +212,10 @@ func Contexter() macaron.Handler { } } - ctx.Data["CsrfToken"] = x.GetToken() - ctx.Data["CsrfTokenHtml"] = template.HTML(``) + ctx.Data["CSRFToken"] = x.GetToken() + ctx.Data["CSRFTokenHTML"] = template.HTML(``) log.Trace("Session ID: %s", sess.ID()) - log.Trace("CSRF Token: %v", ctx.Data["CsrfToken"]) + log.Trace("CSRF Token: %v", ctx.Data["CSRFToken"]) ctx.Data["ShowRegistrationButton"] = setting.Service.ShowRegistrationButton ctx.Data["ShowFooterBranding"] = setting.ShowFooterBranding diff --git a/templates/admin/auth/edit.tmpl b/templates/admin/auth/edit.tmpl index 0879b274b..b06cee8b8 100644 --- a/templates/admin/auth/edit.tmpl +++ b/templates/admin/auth/edit.tmpl @@ -10,7 +10,7 @@
- {{.CsrfTokenHtml}} + {{.CSRFTokenHTML}}
diff --git a/templates/admin/auth/new.tmpl b/templates/admin/auth/new.tmpl index 1edec0cb3..db59856fc 100644 --- a/templates/admin/auth/new.tmpl +++ b/templates/admin/auth/new.tmpl @@ -10,7 +10,7 @@
- {{.CsrfTokenHtml}} + {{.CSRFTokenHTML}}
diff --git a/templates/admin/config.tmpl b/templates/admin/config.tmpl index 4a95a3377..5d10177ad 100644 --- a/templates/admin/config.tmpl +++ b/templates/admin/config.tmpl @@ -178,7 +178,7 @@
{{.i18n.Tr "admin.config.mailer_user"}}
{{if .Mailer.User}}{{.Mailer.User}}{{else}}(empty){{end}}

- {{.CsrfTokenHtml}} + {{.CSRFTokenHTML}}
diff --git a/templates/admin/user/edit.tmpl b/templates/admin/user/edit.tmpl index 34d0da6fc..330745ce0 100644 --- a/templates/admin/user/edit.tmpl +++ b/templates/admin/user/edit.tmpl @@ -10,7 +10,7 @@
- {{.CsrfTokenHtml}} + {{.CSRFTokenHTML}}
{{.User.Name}} diff --git a/templates/admin/user/new.tmpl b/templates/admin/user/new.tmpl index 9352eaace..1827d4f49 100644 --- a/templates/admin/user/new.tmpl +++ b/templates/admin/user/new.tmpl @@ -10,7 +10,7 @@
- {{.CsrfTokenHtml}} + {{.CSRFTokenHTML}}
diff --git a/templates/base/head.tmpl b/templates/base/head.tmpl index 3be2a6bb1..962939dcf 100644 --- a/templates/base/head.tmpl +++ b/templates/base/head.tmpl @@ -9,7 +9,7 @@ {{end}} - + {{if .GoGetImport}} diff --git a/templates/org/create.tmpl b/templates/org/create.tmpl index 765ef240e..6746adc91 100644 --- a/templates/org/create.tmpl +++ b/templates/org/create.tmpl @@ -3,7 +3,7 @@
- {{.CsrfTokenHtml}} + {{.CSRFTokenHTML}}

{{.i18n.Tr "new_org"}}

diff --git a/templates/org/member/invite.tmpl b/templates/org/member/invite.tmpl index 29e7928f0..9913b62c2 100644 --- a/templates/org/member/invite.tmpl +++ b/templates/org/member/invite.tmpl @@ -6,7 +6,7 @@ {{template "base/alert" .}}

{{.i18n.Tr "org.members.invite_desc" .Org.DisplayName}}

- {{.CsrfTokenHtml}} + {{.CSRFTokenHTML}}
diff --git a/templates/org/settings/delete.tmpl b/templates/org/settings/delete.tmpl index dc1858e5c..6f5aa54ec 100644 --- a/templates/org/settings/delete.tmpl +++ b/templates/org/settings/delete.tmpl @@ -14,7 +14,7 @@

{{.i18n.Tr "org.settings.delete_prompt" | Str2html}}

- {{.CsrfTokenHtml}} + {{.CSRFTokenHTML}}
diff --git a/templates/org/settings/options.tmpl b/templates/org/settings/options.tmpl index 804136543..dcd8d33b2 100644 --- a/templates/org/settings/options.tmpl +++ b/templates/org/settings/options.tmpl @@ -11,7 +11,7 @@
- {{.CsrfTokenHtml}} + {{.CSRFTokenHTML}}
@@ -51,7 +51,7 @@
- {{.CsrfTokenHtml}} + {{.CSRFTokenHTML}}
diff --git a/templates/org/team/members.tmpl b/templates/org/team/members.tmpl index c9240beb2..1c707e93b 100644 --- a/templates/org/team/members.tmpl +++ b/templates/org/team/members.tmpl @@ -25,7 +25,7 @@ {{if .IsOrganizationOwner}}
- {{.CsrfTokenHtml}} + {{.CSRFTokenHTML}}
diff --git a/templates/org/team/new.tmpl b/templates/org/team/new.tmpl index 020eed384..e3e99d813 100644 --- a/templates/org/team/new.tmpl +++ b/templates/org/team/new.tmpl @@ -4,7 +4,7 @@
- {{.CsrfTokenHtml}} + {{.CSRFTokenHTML}}

{{if .PageIsOrgTeamsNew}}{{.i18n.Tr "org.create_new_team"}}{{else}}{{.i18n.Tr "org.teams.settings"}}{{end}}

diff --git a/templates/org/team/repositories.tmpl b/templates/org/team/repositories.tmpl index cc79dd189..480e86c43 100644 --- a/templates/org/team/repositories.tmpl +++ b/templates/org/team/repositories.tmpl @@ -26,7 +26,7 @@ {{if $canAddRemove}}
- {{.CsrfTokenHtml}} + {{.CSRFTokenHTML}}
diff --git a/templates/repo/create.tmpl b/templates/repo/create.tmpl index 59bc252c7..4bf9081d0 100644 --- a/templates/repo/create.tmpl +++ b/templates/repo/create.tmpl @@ -3,7 +3,7 @@
- {{.CsrfTokenHtml}} + {{.CSRFTokenHTML}}

{{.i18n.Tr "new_repo"}}

diff --git a/templates/repo/editor/delete.tmpl b/templates/repo/editor/delete.tmpl index a87425307..4506840bb 100644 --- a/templates/repo/editor/delete.tmpl +++ b/templates/repo/editor/delete.tmpl @@ -4,7 +4,7 @@
{{template "base/alert" .}} - {{.CsrfTokenHtml}} + {{.CSRFTokenHTML}} {{template "repo/editor/commit_form" .}}
diff --git a/templates/repo/editor/edit.tmpl b/templates/repo/editor/edit.tmpl index 64b09c374..67a679d92 100644 --- a/templates/repo/editor/edit.tmpl +++ b/templates/repo/editor/edit.tmpl @@ -4,7 +4,7 @@
{{template "base/alert" .}}
- {{.CsrfTokenHtml}} + {{.CSRFTokenHTML}}