WC_Abstract_Order::type_to_group( string $type )
Convert a type to a types group.
Description Description
Parameters Parameters
- $type
-
(Required) type to lookup.
Return Return
(string)
Source Source
File: includes/abstracts/abstract-wc-order.php
protected function type_to_group( $type ) { $type_to_group = apply_filters( 'woocommerce_order_type_to_group', array( 'line_item' => 'line_items', 'tax' => 'tax_lines', 'shipping' => 'shipping_lines', 'fee' => 'fee_lines', 'coupon' => 'coupon_lines', ) ); return isset( $type_to_group[ $type ] ) ? $type_to_group[ $type ] : ''; }