updated plugin Jetpack Protect
version 3.0.2
This commit is contained in:
@ -9,6 +9,7 @@
|
||||
// drop data into `$wp_filter` for `WP_Hook::build_preinitialized_hooks()`.
|
||||
if ( function_exists( 'add_action' ) ) {
|
||||
add_action( 'wp_default_scripts', array( Automattic\Jetpack\Assets::class, 'wp_default_scripts_hook' ) );
|
||||
add_action( 'plugins_loaded', array( Automattic\Jetpack\Assets\Script_Data::class, 'configure' ), 1 );
|
||||
} else {
|
||||
global $wp_filter;
|
||||
// phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited
|
||||
@ -16,4 +17,9 @@ if ( function_exists( 'add_action' ) ) {
|
||||
'accepted_args' => 1,
|
||||
'function' => array( Automattic\Jetpack\Assets::class, 'wp_default_scripts_hook' ),
|
||||
);
|
||||
// phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited
|
||||
$wp_filter['plugins_loaded'][1][] = array(
|
||||
'accepted_args' => 0,
|
||||
'function' => array( Automattic\Jetpack\Assets\Script_Data::class, 'configure' ),
|
||||
);
|
||||
}
|
||||
|
Reference in New Issue
Block a user