]> source.dussan.org Git - gitea.git/commitdiff
Allow passcode invalid error to appear (#14371)
authorAsh McKenzie <ash@the-rebellion.net>
Mon, 18 Jan 2021 08:51:32 +0000 (19:51 +1100)
committerGitHub <noreply@github.com>
Mon, 18 Jan 2021 08:51:32 +0000 (03:51 -0500)
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
routers/user/setting/security_twofa.go

index 4ee698e15e66f5a5e8d7e666822467abb26d076d..925fc2a443001602c58f5959d0e4672f45b60bc8 100644 (file)
@@ -195,7 +195,7 @@ func EnrollTwoFactorPost(ctx *context.Context, form auth.TwoFactorAuthForm) {
                        return
                }
                ctx.Flash.Error(ctx.Tr("settings.passcode_invalid"))
-               ctx.HTML(200, tplSettingsTwofaEnroll)
+               ctx.Redirect(setting.AppSubURL + "/user/settings/security/two_factor/enroll")
                return
        }