WC_Shipping::reset_shipping()publicWC 1.0

Reset shipping.

Reset the totals for shipping as a whole.

Метод класса: WC_Shipping{}

Хуков нет.

Возвращает

null. Ничего (null).

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

$WC_Shipping = new WC_Shipping();
$WC_Shipping->reset_shipping();

Код WC_Shipping::reset_shipping() WC 8.7.0

public function reset_shipping() {
	unset( WC()->session->chosen_shipping_methods );
	$this->packages = array();
}