bump damsel, mamsel (#24)

This commit is contained in:
Anatoly Karlov 2021-05-17 14:45:01 +03:00 committed by GitHub
parent 2d5eb3bd11
commit a6e35093f9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 6 additions and 5 deletions

View File

@ -6,7 +6,7 @@
<parent>
<groupId>com.rbkmoney</groupId>
<artifactId>service-parent-pom</artifactId>
<version>1.2.1</version>
<version>1.2.2</version>
</parent>
<artifactId>fraudbusters-mg-connector</artifactId>

View File

@ -3,7 +3,7 @@ package com.rbkmoney.fraudbusters.mg.connector.converter;
import com.rbkmoney.damsel.domain.BankCard;
import com.rbkmoney.damsel.domain.LegacyBankCardPaymentSystem;
import com.rbkmoney.damsel.domain.PaymentSystemRef;
import com.rbkmoney.damsel.domain.Residence;
import com.rbkmoney.damsel.domain.CountryCode;
import com.rbkmoney.damsel.fraudbusters.CryptoWallet;
import com.rbkmoney.damsel.fraudbusters.Resource;
import com.rbkmoney.fraudbusters.mg.connector.exception.UnknownResourceException;
@ -44,7 +44,7 @@ public class FistfulResourceToDomainResourceConverter
BankCard bankCard = new BankCard();
bankCard.setToken(bankCardFrom.getToken());
bankCard.setIssuerCountry(bankCardFrom.isSetIssuerCountry()
? Residence.valueOf(bankCardFrom.getIssuerCountry().name())
? CountryCode.valueOf(bankCardFrom.getIssuerCountry().name())
: null);
bankCard.setPaymentSystem(bankCardFrom.isSetPaymentSystem()
? new PaymentSystemRef(bankCardFrom.getPaymentSystem().name())

View File

@ -104,6 +104,7 @@ public class PaymentMapper implements Mapper<InvoiceChange, MachineEvent, Paymen
}
public boolean isMobile(PaymentTool paymentTool) {
return paymentTool.isSetBankCard() && TokenProviderUtil.isSetTokenProvider(paymentTool.getBankCard());
return paymentTool.isSetBankCard() && TokenProviderUtil.getTokenProviderName(paymentTool.getBankCard()) != null;
}
}

View File

@ -418,7 +418,7 @@ public class MgEventSinkFlowGenerator {
.setPaymentSystem(new PaymentSystemRef(LegacyBankCardPaymentSystem.mastercard.name()))
.setBin(BIN)
.setLastDigits("4242")
.setIssuerCountry(Residence.RUS)
.setIssuerCountry(CountryCode.RUS)
);
return paymentTool;
}