WordPress at Your Fingertips
function is not described

WC_Tax::sort_rates() private WC 1.0

Logical sort order for tax rates based on the following in order of priority.

{} It's a method of the class: WC_Tax{}

No Hooks.

Return

Array.

Usage

$result = WC_Tax::sort_rates( $rates );
$rates(array) (required)
Rates to be sorted.

Code of WC_Tax::sort_rates() WC 5.9.0

private static function sort_rates( $rates ) {
	uasort( $rates, __CLASS__ . '::sort_rates_callback' );
	$i = 0;
	foreach ( $rates as $key => $rate ) {
		$rates[ $key ]->tax_rate_order = $i++;
	}
	return $rates;
}