Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

Depend on subscription-past-due events to trigger the account-on-hold email

vishnukvmda131c16f4e82
diff --git a/server/pkg/controller/stripe.go b/server/pkg/controller/stripe.go
index d065714ef6..c8c70cc582 100644
--- a/server/pkg/controller/stripe.go
+++ b/server/pkg/controller/stripe.go
@@ -404,20 +404,6 @@ func (c *StripeController) handlePaymentIntentFailed(event stripe.Event, country
if err != nil {
return ente.StripeEventLog{}, stacktrace.Propagate(err, "")
}
- // Send an email to the user
- user, err := c.UserRepo.Get(userID)
- if err != nil {
- return ente.StripeEventLog{}, stacktrace.Propagate(err, "")
- }
- // TODO: Inform customer that payment_failed.html with invoice.HostedInvoiceURL
- err = email.SendTemplatedEmail([]string{user.Email}, "ente", "[email protected]",
- ente.AccountOnHoldEmailSubject, ente.OnHoldTemplate, map[string]interface{}{
- "PaymentProvider": "Stripe",
- "InvoiceURL": invoice.HostedInvoiceURL,
- }, nil)
- if err != nil {
- return ente.StripeEventLog{}, stacktrace.Propagate(err, "")
- }
return ente.StripeEventLog{UserID: userID, StripeSubscription: *stripeSubscription, Event: event}, nil
}