MCPcopy Create free account
hub / github.com/gogs/gogs / LoginTwoFactorRecoveryCode

Function LoginTwoFactorRecoveryCode

internal/route/user/auth.go:250–258  ·  view source on GitHub ↗
(c *context.Context)

Source from the content-addressed store, hash-verified

248}
249
250func LoginTwoFactorRecoveryCode(c *context.Context) {
251 _, ok := c.Session.Get("twoFactorUserID").(int64)
252 if !ok {
253 c.NotFound()
254 return
255 }
256
257 c.Success(tmplUserAuthTwoFactorRecoveryCode)
258}
259
260func LoginTwoFactorRecoveryCodePost(c *context.Context) {
261 userID, ok := c.Session.Get("twoFactorUserID").(int64)

Callers

nothing calls this directly

Calls 3

SuccessMethod · 0.80
GetMethod · 0.65
NotFoundMethod · 0.65

Tested by

no test coverage detected