mirror of
https://github.com/bitwarden/server.git
synced 2025-05-20 11:04:31 -05:00
check receiver after txn_type
This commit is contained in:
parent
5103a05332
commit
e2df614cd5
@ -193,12 +193,6 @@ namespace Bit.Billing.Controllers
|
|||||||
}
|
}
|
||||||
|
|
||||||
var ipnTransaction = new PayPalIpnClient.IpnTransaction(body);
|
var ipnTransaction = new PayPalIpnClient.IpnTransaction(body);
|
||||||
if(ipnTransaction.ReceiverId != _billingSettings.PayPal.BusinessId)
|
|
||||||
{
|
|
||||||
_logger.LogWarning("Receiver was not proper business id. " + ipnTransaction.ReceiverId);
|
|
||||||
return new BadRequestResult();
|
|
||||||
}
|
|
||||||
|
|
||||||
if(ipnTransaction.TxnType != "web_accept" && ipnTransaction.TxnType != "merch_pmt" &&
|
if(ipnTransaction.TxnType != "web_accept" && ipnTransaction.TxnType != "merch_pmt" &&
|
||||||
ipnTransaction.PaymentStatus != "Refunded")
|
ipnTransaction.PaymentStatus != "Refunded")
|
||||||
{
|
{
|
||||||
@ -206,6 +200,12 @@ namespace Bit.Billing.Controllers
|
|||||||
return new OkResult();
|
return new OkResult();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(ipnTransaction.ReceiverId != _billingSettings.PayPal.BusinessId)
|
||||||
|
{
|
||||||
|
_logger.LogWarning("Receiver was not proper business id. " + ipnTransaction.ReceiverId);
|
||||||
|
return new BadRequestResult();
|
||||||
|
}
|
||||||
|
|
||||||
if(ipnTransaction.PaymentType == "echeck")
|
if(ipnTransaction.PaymentType == "echeck")
|
||||||
{
|
{
|
||||||
// Not accepting eChecks
|
// Not accepting eChecks
|
||||||
|
Loading…
x
Reference in New Issue
Block a user