add: some user api and all api desc
This commit is contained in:
@@ -7,7 +7,7 @@ import (
|
||||
"juwan-backend/app/users/rpc/internal/svc"
|
||||
utils2 "juwan-backend/app/users/rpc/internal/utils"
|
||||
"juwan-backend/app/users/rpc/pb"
|
||||
"juwan-backend/common/utils"
|
||||
"juwan-backend/common/utils/pwdUtils"
|
||||
|
||||
"github.com/zeromicro/go-zero/core/logx"
|
||||
)
|
||||
@@ -36,7 +36,7 @@ func (l *LoginLogic) Login(in *pb.LoginReq) (*pb.LoginResp, error) {
|
||||
return nil, err
|
||||
}
|
||||
logx.Infof("user:%v", user)
|
||||
if !utils.VerifyPassword(user.PasswordHash, in.Passwd) {
|
||||
if !pwdUtils.VerifyPassword(user.PasswordHash, in.Passwd) {
|
||||
logx.WithContext(l.ctx).Errorf("User %s Login failed", user.Username)
|
||||
return nil, errors.New("incorrect password")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user