二测质押用户奖励
This commit is contained in:
@@ -33,7 +33,7 @@ func (l *BindWalletLogic) BindWallet(req *types.EmailKey) *types.CarvResult {
|
||||
return errResult
|
||||
}
|
||||
|
||||
_, err := l.svcCtx.WalletModel.FindAddressByUid(l.ctx, uid)
|
||||
pb, err := l.svcCtx.PromoteBindModel.FindOneByInvitedUid(l.ctx, uid)
|
||||
if err != nil {
|
||||
if !errors.Is(err, model.ErrNotFound) {
|
||||
return &types.CarvResult{
|
||||
@@ -47,6 +47,15 @@ func (l *BindWalletLogic) BindWallet(req *types.EmailKey) *types.CarvResult {
|
||||
Result: &types.Result{IsValid: false},
|
||||
}
|
||||
}
|
||||
|
||||
shareId := l.svcCtx.ConfigModel.GetCarvIoInviterId(l.ctx)
|
||||
|
||||
if pb.ShareUid != shareId || pb.IsBindWallet == 0 {
|
||||
return &types.CarvResult{
|
||||
Result: &types.Result{IsValid: false},
|
||||
}
|
||||
}
|
||||
|
||||
return &types.CarvResult{
|
||||
Result: &types.Result{IsValid: true},
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user