Merge pull request #30404 from woocommerce/fix/30390
Fix 'woocommerce_email_settings' filter being triggered twice
This commit is contained in:
commit
23ae6993ff
|
@ -51,8 +51,7 @@ class WC_Settings_Emails extends WC_Settings_Page {
|
|||
'https://wordpress.org/plugins/wp-mail-logging/',
|
||||
'https://docs.woocommerce.com/document/email-faq'
|
||||
);
|
||||
$settings = apply_filters(
|
||||
'woocommerce_email_settings',
|
||||
$settings =
|
||||
array(
|
||||
array(
|
||||
'title' => __( 'Email notifications', 'woocommerce' ),
|
||||
|
@ -217,8 +216,7 @@ class WC_Settings_Emails extends WC_Settings_Page {
|
|||
'type' => 'sectionend',
|
||||
'id' => 'email_merchant_notes',
|
||||
),
|
||||
)
|
||||
);
|
||||
);
|
||||
|
||||
return apply_filters( 'woocommerce_email_settings', $settings );
|
||||
}
|
||||
|
|
|
@ -5,7 +5,6 @@
|
|||
* @package WooCommerce\Tests\Settings
|
||||
*/
|
||||
|
||||
use Automattic\WooCommerce\Testing\Tools\CodeHacking\Hacks\FunctionsMockerHack;
|
||||
use Automattic\WooCommerce\Testing\Tools\CodeHacking\Hacks\StaticMockerHack;
|
||||
|
||||
require_once __DIR__ . '/class-wc-settings-unit-test-case.php';
|
||||
|
|
Loading…
Reference in New Issue