From f960e19c590d27fe62a3a6241f1ea8b7fadde13a Mon Sep 17 00:00:00 2001 From: Lunny Xiao Date: Sat, 12 Aug 2017 22:18:44 +0800 Subject: Only update needed columns when update user (#2296) * only update needed columns when update user * fix missing update_unix column --- cmd/admin.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'cmd') diff --git a/cmd/admin.go b/cmd/admin.go index aec1b8dad4..928bc1ebba 100644 --- a/cmd/admin.go +++ b/cmd/admin.go @@ -103,7 +103,7 @@ func runChangePassword(c *cli.Context) error { return fmt.Errorf("%v", err) } user.EncodePasswd() - if err := models.UpdateUser(user); err != nil { + if err := models.UpdateUserCols(user, "passwd", "salt"); err != nil { return fmt.Errorf("%v", err) } -- cgit v1.2.3