deprecated_function_run хук-событиеWC 3.0.0

Это хук WordPress - deprecated_function_run. Плагин его просто использует.

Wrapper for deprecated functions so we can apply some extra logic.

Использование

add_action( 'deprecated_function_run', 'wp_kama_deprecated_function_run_action', 10, 3 );

/**
 * Function for `deprecated_function_run` action-hook.
 * 
 * @param string $function_name The function that was called.
 * @param string $replacement   The function that should have been called.
 * @param string $version       The version of WordPress that deprecated the function.
 *
 * @return void
 */
function wp_kama_deprecated_function_run_action( $function_name, $replacement, $version ){

	// action...
}
$function_name(строка)
The function that was called.
$replacement(строка)
The function that should have been called.
$version(строка)
The version of WordPress that deprecated the function.

Список изменений

С версии 3.0.0 Введена.

Где вызывается хук

wc_deprecated_function()
deprecated_function_run
Bootstrap::deprecated_dependency()
deprecated_function_run
woocommerce/includes/wc-deprecated-functions.php 51
do_action( 'deprecated_function_run', $function, $replacement, $version );
woocommerce/src/Blocks/Domain/Bootstrap.php 472
do_action( 'deprecated_function_run', $function, $replacement, $version );

Где используется хук в WooCommerce

Использование не найдено.