Skip to content

Commit

Permalink
Remove mailer lite hook
Browse files Browse the repository at this point in the history
  • Loading branch information
zachaysan committed Oct 8, 2024
1 parent 7ce945c commit 9d453e2
Showing 1 changed file with 0 additions and 8 deletions.
8 changes: 0 additions & 8 deletions api/organisations/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@
)
from organisations.subscriptions.metadata import BaseSubscriptionMetadata
from organisations.subscriptions.xero.metadata import XeroSubscriptionMetadata
from users.utils.mailer_lite import MailerLite
from webhooks.models import AbstractBaseExportableWebhookModel

environment_cache = caches[settings.ENVIRONMENT_CACHE_NAME]
Expand Down Expand Up @@ -280,13 +279,6 @@ def update_hubspot_active_subscription(self):

update_hubspot_active_subscription.delay(args=(self.id,))

@hook(AFTER_SAVE, when="cancellation_date", has_changed=True)
@hook(AFTER_SAVE, when="subscription_id", has_changed=True)
def update_mailer_lite_subscribers(self):
if settings.MAILERLITE_API_KEY:
mailer_lite = MailerLite()
mailer_lite.update_organisation_users(self.organisation.id)

def save_as_free_subscription(self):
"""
Wipes a subscription to a normal free plan.
Expand Down

0 comments on commit 9d453e2

Please sign in to comment.