mirror of
https://github.com/pretix/pretix.git
synced 2026-05-04 15:04:03 +00:00
Correctly respect mail_attach_ical setting on order payments
This commit is contained in:
@@ -1338,7 +1338,8 @@ class OrderPayment(models.Model):
|
||||
email_subject, email_template, email_context,
|
||||
'pretix.event.order.email.order_paid', user,
|
||||
invoices=[], position=position,
|
||||
attach_tickets=True, attach_ical=True
|
||||
attach_tickets=True,
|
||||
attach_ical=self.order.event.settings.mail_attach_ical
|
||||
)
|
||||
except SendMailException:
|
||||
logger.exception('Order paid email could not be sent')
|
||||
@@ -1355,7 +1356,8 @@ class OrderPayment(models.Model):
|
||||
email_subject, email_template, email_context,
|
||||
'pretix.event.order.email.order_paid', user,
|
||||
invoices=[invoice] if invoice and self.order.event.settings.invoice_email_attachment else [],
|
||||
attach_tickets=True, attach_ical=True
|
||||
attach_tickets=True,
|
||||
attach_ical=self.order.event.settings.mail_attach_ical
|
||||
)
|
||||
except SendMailException:
|
||||
logger.exception('Order paid email could not be sent')
|
||||
|
||||
Reference in New Issue
Block a user