This commit is contained in:
wangchuxiao 2023-03-17 12:32:26 +08:00
parent 506a417b0b
commit 1921e5b030

View File

@ -75,7 +75,7 @@ func (f *friendDatabase) AddFriendRequest(ctx context.Context, fromUserID, toUse
_, err := f.friendRequest.NewTx(tx).Take(ctx, fromUserID, toUserID)
//有db错误
if err != nil && errors.Unwrap(err) != gorm.ErrRecordNotFound {
log.ZDebug(ctx, "AddFriendRequest err", "bool", errors.Unwrap(err) != gorm.ErrRecordNotFound, "err", err, "unwrap", errors.Unwrap(err))
log.ZDebug(ctx, "AddFriendRequest err", "bool", errors.Unwrap(err) != gorm.ErrRecordNotFound, "err", err.Error(), "unwrap", errors.Unwrap(err).Error())
return err
}
//无错误 则更新