This commit is contained in:
eson 2023-08-30 16:28:55 +08:00
parent 4c45b2287a
commit da40278e26
2 changed files with 3 additions and 2 deletions

View File

@ -120,11 +120,12 @@ func (l *UserEmailConfirmationLogic) UserEmailConfirmation(req *types.RequestEma
logx.Info("success", token.TraceId)
case string(auth.PLATFORM_FACEBOOK):
case string(auth.PLATFORM_FUSEN):
// log.Println("aaaa", token)
user, err := l.svcCtx.AllModels.FsUser.RegisterByFusen(l.ctx, token)
if err != nil && err != gorm.ErrRecordNotFound {
logx.Error(err, ":", token.TraceId)
logx.Error(err)
return resp.SetStatusWithMessage(basic.CodeDbSqlErr, err.Error())
}
err = FinishRegister(l.svcCtx, user, token)

View File

@ -132,7 +132,7 @@ func (l *UserGoogleLoginLogic) AfterLogic(w http.ResponseWriter, r *http.Request
if resp.Code == 200 {
rurl := fmt.Sprintf(
"http://www.fusen.3718.cn/"+"/oauth?token=%s&is_registered=%t&register_token=%s",
"http://www.fusen.3718.cn"+"/oauth?token=%s&is_registered=%t&register_token=%s",
l.token,
l.isRegistered,
l.registerToken,