Refactor code

This commit is contained in:
wenxu12345
2021-12-31 10:57:45 +08:00
parent cd62d7f0d9
commit 87659b56a4
4 changed files with 28 additions and 27 deletions
+1 -1
View File
@@ -213,7 +213,7 @@ func (s *userServer) UpdateUserInfo(ctx context.Context, req *pbUser.UpdateUserI
return &pbUser.UpdateUserInfoResp{CommonResp: &pbUser.CommonResp{ErrCode: constant.ErrAccess.ErrCode, ErrMsg: constant.ErrAccess.ErrMsg}}, nil
}
var user imdb.User
var user db.User
utils.CopyStructFields(&user, req.UserInfo)
if req.UserInfo.Birth != 0 {
user.Birth = utils.UnixSecondToTime(req.UserInfo.Birth)