Hi there, I've been working with Mailchimp on this issue and they have suggested I bring it up with you guys.
We already had a list of subscribers from our site which used to have a simple sign up field on registration, every week we manually imported these new subscribers to our list in mailchimp. As we wanted to make it as automated as possible we added the Mailchimp module a few weeks ago and replaced the signup field with the Mailchimp sign up field.
Everything worked fine until we started getting emails from Mailchimp to our test accounts asking us to subscribe to our list, these accounts hadn't been accessed for a while, then we started getting people resubscribing, again users who hadn't been on the site for a while. I presumed it was a Mailchimp issue to do with resubscribing but they have said the following:
Thanks for following up with us and providing us that extra bit of info. In this particular situation, the subscribers are being added via a 3rd party integration that is using the API to pass information to MailChimp. The best thing we can recommend in this situation is to reach out to the folks who made this particular integration to see what the behavior is if someone is already on the list and are added again via the integration. They may have some tips to prevent them from going through the double opt-in process again.
We can confirm that these emails are being triggered because they are being added to the list with double opt-in enabled. Essentially the integration team that made this is going to need to be worked with to figure out what the expected behaviors are with this specific integration, as well as see if they have a way of turning this behavior off within the integration's settings.
The strange thing is that I have never turned on the double opt in option on the module nor have a lot of these people actively been added via the API. Is there a way around this as we're getting complaints that we're spamming people (even though in reality it's just a double confirmation not anything malicious).
I can't work out whether this is actually related to a bug in the double opt in or in fact it is working as expected but it's something that potentially needs to be changed so that if subscribers are already on the list then they should not be added to the list again or sent a confirmation email.
Thanks,
Comments
Comment #1
gc11 commentedHi any chance of a reply to this? It now seems people are getting these emails more than once, which is obviously harder to manage.
Thanks.
Comment #2
hibersh commentedComment #3
silkogelman commentedIs this a Mailchimp module issue or a Commerce Mailchimp module issue?
@gc11 can you describe what versions of the modules you are using and in what way the cases relate to commerce_mailchimp module?
Comment #4
mixedfeelings commentedI am actually the same problem described in the no-list during checkout thread, but in this case: https://drupal.org/node/1967836
It's the exact same error but only for repeat customers where the user is already on the list.
I am using the newest versions of the mailchimp and commerce_mailchimp modules.
Any ideas?
Comment #5
bensey commentedHi guys,
have run into this issue myself, and it has nothing to do with the double opt-in.
It's caused by the signup pane form function and it's validation function. The signup pane checks if the user's email address is already on the list, and doesn't display the pane if the user is already subscribed to the list. The validation function works using the
$form_state['values']['commerce_mailchimp']array. This is not defined if the pane is not displayed (because the user was already subscribed), and therefore doesn't make it onto the$form_statearray, causing the error.My solution to this was to just add a check to see if
$form_state['values']['commerce_mailchimp']is actually set in the$form_statearray so it doesn't try to operate on an array that doesn't exist.Updated function is below.
Comment #7
jim.m commentedThanks for the contribution bensey.