Minor fixes for braintree credit card failures

This commit is contained in:
David Bomba 2022-01-24 14:45:57 +11:00
parent 3ac8d456d5
commit 4c68d6ba79
2 changed files with 4 additions and 3 deletions

View File

@ -418,12 +418,15 @@ class BaseDriver extends AbstractPaymentDriver
throw new PaymentFailed($error, $e->getCode());
}
public function sendFailureMail($error = '')
public function sendFailureMail($error)
{
if (!is_null($this->payment_hash)) {
$this->unWindGatewayFees($this->payment_hash);
}
if(!$error)
$error = '';
PaymentFailedMailer::dispatch(
$this->payment_hash,

View File

@ -92,8 +92,6 @@ class PaymentIntentWebhook implements ShouldQueue
$this->updateCreditCardPayment($payment_hash, $client);
}
//create the payment
}
}