Automattic\WooCommerce\Blocks\Utils

CartCheckoutUtils::has_cart_pagepublic staticWC 1.0

Check if the cart page is defined.

Method of the class: CartCheckoutUtils{}

No Hooks.

Returns

true|false. True if the cart page is defined, false otherwise.

Usage

$result = CartCheckoutUtils::has_cart_page();

CartCheckoutUtils::has_cart_page() code WC 10.7.0

public static function has_cart_page() {
	return wc_get_page_permalink( 'cart', -1 ) !== -1;
}