diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2021-09-25 22:27:01 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-09-25 16:27:01 +0200 |
commit | 58d81835e2e78cc218d238c580a58cdd54535b44 (patch) | |
tree | 20fc8d6d58581d43a195534e89cc9866afca48e8 /routers | |
parent | 91e21d4fca8b867614d08537e92bc6c8fc7b0444 (diff) | |
download | gitea-58d81835e2e78cc218d238c580a58cdd54535b44.tar.gz gitea-58d81835e2e78cc218d238c580a58cdd54535b44.zip |
Fix wrong i18n keys (#17150)
Co-authored-by: 6543 <6543@obermui.de>
Diffstat (limited to 'routers')
-rw-r--r-- | routers/web/user/setting/keys.go | 2 | ||||
-rw-r--r-- | routers/web/user/setting/security_twofa.go | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/routers/web/user/setting/keys.go b/routers/web/user/setting/keys.go index bb7a50841b..22a0fe4741 100644 --- a/routers/web/user/setting/keys.go +++ b/routers/web/user/setting/keys.go @@ -209,7 +209,7 @@ func DeleteKey(ctx *context.Context) { return } if external { - ctx.Flash.Error(ctx.Tr("setting.ssh_externally_managed")) + ctx.Flash.Error(ctx.Tr("settings.ssh_externally_managed")) ctx.Redirect(setting.AppSubURL + "/user/settings/keys") return } diff --git a/routers/web/user/setting/security_twofa.go b/routers/web/user/setting/security_twofa.go index 5b1cbab17f..94f975f9fe 100644 --- a/routers/web/user/setting/security_twofa.go +++ b/routers/web/user/setting/security_twofa.go @@ -32,7 +32,7 @@ func RegenerateScratchTwoFactor(ctx *context.Context) { t, err := login.GetTwoFactorByUID(ctx.User.ID) if err != nil { if login.IsErrTwoFactorNotEnrolled(err) { - ctx.Flash.Error(ctx.Tr("setting.twofa_not_enrolled")) + ctx.Flash.Error(ctx.Tr("settings.twofa_not_enrolled")) ctx.Redirect(setting.AppSubURL + "/user/settings/security") } ctx.ServerError("SettingsTwoFactor: Failed to GetTwoFactorByUID", err) @@ -62,7 +62,7 @@ func DisableTwoFactor(ctx *context.Context) { t, err := login.GetTwoFactorByUID(ctx.User.ID) if err != nil { if login.IsErrTwoFactorNotEnrolled(err) { - ctx.Flash.Error(ctx.Tr("setting.twofa_not_enrolled")) + ctx.Flash.Error(ctx.Tr("settings.twofa_not_enrolled")) ctx.Redirect(setting.AppSubURL + "/user/settings/security") } ctx.ServerError("SettingsTwoFactor: Failed to GetTwoFactorByUID", err) @@ -150,7 +150,7 @@ func EnrollTwoFactor(ctx *context.Context) { if t != nil { // already enrolled - we should redirect back! log.Warn("Trying to re-enroll %-v in twofa when already enrolled", ctx.User) - ctx.Flash.Error(ctx.Tr("setting.twofa_is_enrolled")) + ctx.Flash.Error(ctx.Tr("settings.twofa_is_enrolled")) ctx.Redirect(setting.AppSubURL + "/user/settings/security") return } @@ -175,7 +175,7 @@ func EnrollTwoFactorPost(ctx *context.Context) { t, err := login.GetTwoFactorByUID(ctx.User.ID) if t != nil { // already enrolled - ctx.Flash.Error(ctx.Tr("setting.twofa_is_enrolled")) + ctx.Flash.Error(ctx.Tr("settings.twofa_is_enrolled")) ctx.Redirect(setting.AppSubURL + "/user/settings/security") return } |