fix
This commit is contained in:
parent
31bb514b34
commit
db2c41f0ce
|
@ -6,9 +6,9 @@ import (
|
|||
"fmt"
|
||||
|
||||
"fusenapi/utils/auth"
|
||||
"log"
|
||||
"time"
|
||||
|
||||
"github.com/zeromicro/go-zero/core/logx"
|
||||
"gorm.io/gorm"
|
||||
)
|
||||
|
||||
|
@ -159,7 +159,7 @@ func (u *FsUserModel) RegisterByFusen(ctx context.Context, token *auth.RegisterT
|
|||
user.LastName = &LastName
|
||||
|
||||
err = UserTx.Create(user).Error
|
||||
log.Println("create")
|
||||
logx.Info("create")
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
@ -200,7 +200,7 @@ func (u *FsUserModel) RegisterByFusen(ctx context.Context, token *auth.RegisterT
|
|||
return err
|
||||
})
|
||||
|
||||
if err != nil {
|
||||
if err != nil && err != gorm.ErrRecordNotFound {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user