1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-10 13:12:50 +01:00

Throw PaymentFailed (generic) exception

This commit is contained in:
Benjamin Beganović 2021-06-15 18:52:15 +02:00
parent 1b7198c1a0
commit 3f729bedde

View File

@ -12,6 +12,7 @@
namespace App\PaymentDrivers;
use App\Exceptions\PaymentFailed;
use App\Factory\PaymentFactory;
use App\Http\Requests\Payments\PaymentWebhookRequest;
use App\Http\Requests\Request;
@ -490,9 +491,7 @@ class StripePaymentDriver extends BaseDriver
return PaymentMethod::retrieve($source, $this->stripe_connect_auth);
} catch (ApiErrorException | Exception $e) {
return $this->processInternallyFailedPayment($this, $e);
throw new PaymentFailed($e->getMessage(), $e->getCode());
}
}