WordPress at a glance
function is not described

wc_deprecated_function() WC 3.0.0

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

Hooks from the function
Return

null. Nothing.

Usage

wc_deprecated_function( $function, $version, $replacement );
$function(string) (required)
Function used.
$version(string) (required)
Version the message was added in.
$replacement(string)
Replacement for the called function.

Changelog

Since 3.0.0 Introduced.

Code of wc_deprecated_function() WC 5.3.0

<?php
function wc_deprecated_function( $function, $version, $replacement = null ) {
	// @codingStandardsIgnoreStart
	if ( is_ajax() || WC()->is_rest_api_request() ) {
		do_action( 'deprecated_function_run', $function, $replacement, $version );
		$log_string  = "The {$function} function is deprecated since version {$version}.";
		$log_string .= $replacement ? " Replace with {$replacement}." : '';
		error_log( $log_string );
	} else {
		_deprecated_function( $function, $version, $replacement );
	}
	// @codingStandardsIgnoreEnd
}