WC_Cart::needs_payment()publicWC 1.0

Looks at the totals to see if payment is actually required.

Method of the class: WC_Cart{}

Hooks from the method

Return

true|false.

Usage

$WC_Cart = new WC_Cart();
$WC_Cart->needs_payment();

WC_Cart::needs_payment() code WC 9.4.2

public function needs_payment() {
	return apply_filters( 'woocommerce_cart_needs_payment', 0 < $this->get_total( 'edit' ), $this );
}