WC_Order_Item_Shipping::offsetExists()publicWC 1.0ReturnTypeWillChange

Offset exists: for ArrayAccess.

Method of the class: WC_Order_Item_Shipping{}

No Hooks.

Return

true|false.

Usage

$WC_Order_Item_Shipping = new WC_Order_Item_Shipping();
$WC_Order_Item_Shipping->offsetExists( $offset );
$offset(string) (required)
Key.

WC_Order_Item_Shipping::offsetExists() code WC 8.7.0

public function offsetExists( $offset ) {
	if ( in_array( $offset, array( 'cost' ), true ) ) {
		return true;
	}
	return parent::offsetExists( $offset );
}