Skip to content

Commit

Permalink
Redirect to correct page after using scratch token (#4458)
Browse files Browse the repository at this point in the history
  • Loading branch information
techknowlogick committed Jul 19, 2018
1 parent d133729 commit 492ec97
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion routers/user/auth.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
// Copyright 2014 The Gogs Authors. All rights reserved.
// Copyright 2018 The Gitea Authors. All rights reserved.
// Use of this source code is governed by a MIT-style
// license that can be found in the LICENSE file.

Expand Down Expand Up @@ -320,7 +321,7 @@ func TwoFactorScratchPost(ctx *context.Context, form auth.TwoFactorScratchAuthFo

handleSignInFull(ctx, u, remember, false)
ctx.Flash.Info(ctx.Tr("auth.twofa_scratch_used"))
ctx.Redirect(setting.AppSubURL + "/user/settings/two_factor")
ctx.Redirect(setting.AppSubURL + "/user/settings/security")
return
}

Expand Down

0 comments on commit 492ec97

Please sign in to comment.