src/Hametuha/HametWoo/Utility/Tools.php
public function get_all_products_in( $order ) {
		$order = wc_get_order( $order );
		if ( ! $order ) {
			return [];
		}
		$products = [];
		foreach ( $order->get_items() as $item ) {
			$products[] = $order->get_product_from_item( $item );
		}
		return $products;
	}
public function get_all_products_in( $order ) {
		$order = wc_get_order( $order );
		if ( ! $order ) {
			return [];
		}
		$products = [];
		foreach ( $order->get_items() as $item ) {
			$products[] = $order->get_product_from_item( $item );
		}
		return $products;
	}
public function get_all_products_in ( $ order ) { $ order = wc_get_order ( $ order ) ; if ( ! $ order ) { return [ ] ; } $ products = [ ] ; foreach ( $ order -> get_items ( ) as $ item ) { $ products [ ] = $ order -> get_product_from_item ( $ item ) ; } return $ products ; }
Get all product in order

@param int|\WC_Order|\stdClass $order Order object.

@since 0.8.3
@return array
Get all product in order