Automattic\WooCommerce\Blocks\BlockTypes\OrderConfirmation

AbstractOrderConfirmationBlock::is_customer_order()protectedWC 1.0

See if the current order came from a guest or a logged in customer.

Method of the class: AbstractOrderConfirmationBlock{}

No Hooks.

Return

true|false.

Usage

// protected - for code of main (parent) or child class
$result = $this->is_customer_order( $order );
$order(\WC_Order) (required)
Order object.

AbstractOrderConfirmationBlock::is_customer_order() code WC 9.0.1

protected function is_customer_order( $order ) {
	return 0 < $order->get_user_id();
}