WordPress at a glance
function is not described

WC_Cart_Fees::sort_fees_callback() protected WC 1.0

Sort fees by amount.

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

Hooks from the method
Return

Int. Nothing.

Usage

// protected - for code of main (parent) or child class
$result = $this->sort_fees_callback( $a, $b );
$a(stdClass) (required)
Fee object.
$b(stdClass) (required)
Fee object.

Code of WC_Cart_Fees::sort_fees_callback() WC 5.3.0

<?php
protected function sort_fees_callback( $a, $b ) {
	/**
	 * Filter sort fees callback.
	 *
	 * @since 3.8.0
	 * @param int Sort order, -1 or 1.
	 * @param stdClass $a Fee object.
	 * @param stdClass $b Fee object.
	 */
	return apply_filters( 'woocommerce_sort_fees_callback', $a->amount > $b->amount ? -1 : 1, $a, $b );
}