fix: do not send telegram noti on intent payment failed

This commit is contained in:
Andras Bacsai 2023-12-11 08:32:42 +01:00
parent 6f97af096d
commit 771dc30b81

View File

@ -640,7 +640,9 @@
// Unhandled event type
}
} catch (Exception $e) {
send_internal_notification("Subscription webhook ($type) failed: " . $e->getMessage());
if ($type !== 'payment_intent.payment_failed') {
send_internal_notification("Subscription webhook ($type) failed: " . $e->getMessage());
}
$webhook->update([
'status' => 'failed',
'failure_reason' => $e->getMessage(),