aboutsummaryrefslogtreecommitdiff
path: root/internal/route/user/setting.go
diff options
context:
space:
mode:
authorJoe Chen <jc@unknwon.io>2022-06-11 09:42:17 +0800
committerGitHub <noreply@github.com>2022-06-11 09:42:17 +0800
commitf837ea6346ac720d586eda51ab89c5c71a1f3e65 (patch)
tree678b0bdccee80e65c399e8696cd209c9e902618d /internal/route/user/setting.go
parent9776bdc9b8b441ebd73c100bfe2aa4e495c233ca (diff)
db: use `context` and go-mockgen for `UsersStore` (#7042)
Diffstat (limited to 'internal/route/user/setting.go')
-rw-r--r--internal/route/user/setting.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/internal/route/user/setting.go b/internal/route/user/setting.go
index cf2226c5..c28a1747 100644
--- a/internal/route/user/setting.go
+++ b/internal/route/user/setting.go
@@ -640,7 +640,7 @@ func SettingsDelete(c *context.Context) {
c.PageIs("SettingsDelete")
if c.Req.Method == "POST" {
- if _, err := db.Users.Authenticate(c.User.Name, c.Query("password"), c.User.LoginSource); err != nil {
+ if _, err := db.Users.Authenticate(c.Req.Context(), c.User.Name, c.Query("password"), c.User.LoginSource); err != nil {
if auth.IsErrBadCredentials(err) {
c.RenderWithErr(c.Tr("form.enterred_invalid_password"), SETTINGS_DELETE, nil)
} else {