Merge pull request #8365 from tamarazuk/master

[2.3] Email settings save tweak
This commit is contained in:
Mike Jolley 2015-06-16 14:43:07 +01:00
commit 2501af0376
1 changed files with 3 additions and 3 deletions

View File

@ -202,9 +202,9 @@ class WC_Settings_Emails extends WC_Settings_Page {
$wc_emails = WC_Emails::instance();
if ( in_array( $current_section, array_map( 'sanitize_title', array_keys( $wc_emails->get_emails() ) ) ) ) {
foreach ( $wc_emails->get_emails() as $email ) {
if ( $current_section === sanitize_title( get_class( $email ) ) ) {
do_action( 'woocommerce_update_options_' . $this->id . '_' . $email->id );
foreach ( $wc_emails->get_emails() as $email_id => $email ) {
if ( $current_section === sanitize_title( $email_id ) ) {
do_action( 'woocommerce_update_options_' . $this->id . '_' . $email_id );
}
}
} else {