Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

REFACTOR: Logic changed on how we add the user to a list. #15

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from

Conversation

andrewlimaza
Copy link

  • Updated logic on how we add a subscriber to a MailPoet list to prevent fatal errors in some cases. This fixed an issue with guest checkouts.

* Updated logic on how we add a subscriber to a MailPoet list.
@andrewlimaza
Copy link
Author

This fixes a fatal error where it's unable to send the subscribed confirmation email, when trying to add the user to a list.

@dparker1005
Copy link
Member

After looking into this a bit, I have concerns about using the addSubscriber() method as I think we may hit the "This subscriber already exists" exception and the user may not actually be added to the MailPoet list:
https://github.com/mailpoet/mailpoet/blob/d4e239ace521341ff9015d15cb16c5e93bbf9ff9/mailpoet/lib/API/MP/v1/Subscribers.php#L117-L123

Looking into the original fatal error again, it looks like this fatal error shows when MailPoet is trying to sent emails via their premium email service instead of just letting the website send the emails. I was able to disable connecting to the premium email service by going to MailPoet > Settings > Send With... and selecting "Other".

Let me know if this makes sense or if you still think we need this PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants