Fix - Incorrect action as it was filter hook

This commit is contained in:
Shiva Poudel 2018-02-06 01:15:47 +05:45
parent 750e0e78e4
commit 8a35c8fc23
1 changed files with 3 additions and 5 deletions

View File

@ -2,10 +2,8 @@
/** /**
* WooCommerce Admin Webhooks Class * WooCommerce Admin Webhooks Class
* *
* @author Automattic * @package WooCommerce\Admin
* @category Admin * @version 3.3.0
* @package WooCommerce/Admin
* @version 3.3.0
*/ */
if ( ! defined( 'ABSPATH' ) ) { if ( ! defined( 'ABSPATH' ) ) {
@ -21,7 +19,7 @@ class WC_Admin_Webhooks {
* Initialize the webhooks admin actions. * Initialize the webhooks admin actions.
*/ */
public function __construct() { public function __construct() {
add_action( 'woocommerce_save_settings_api_webhooks', array( $this, 'allow_save_settings' ) ); add_filter( 'woocommerce_save_settings_api_webhooks', array( $this, 'allow_save_settings' ) );
add_action( 'admin_init', array( $this, 'actions' ) ); add_action( 'admin_init', array( $this, 'actions' ) );
} }