Automattic\WooCommerce\Internal\Admin\Onboarding
OnboardingMailchimp::on_profile_data_updated()
Reset MailchimpScheduler if profile data is being updated with a new email.
Method of the class: OnboardingMailchimp{}
No Hooks.
Return
null
. Nothing (null).
Usage
$OnboardingMailchimp = new OnboardingMailchimp(); $OnboardingMailchimp->on_profile_data_updated( $existing_data, $updating_data );
- $existing_data(array) (required)
- Existing option data.
- $updating_data(array) (required)
- Updating option data.
OnboardingMailchimp::on_profile_data_updated() OnboardingMailchimp::on profile data updated code WC 9.3.3
public function on_profile_data_updated( $existing_data, $updating_data ) { if ( isset( $existing_data['store_email'] ) && isset( $updating_data['store_email'] ) && $existing_data['store_email'] !== $updating_data['store_email'] ) { MailchimpScheduler::reset(); } }