WC_Legacy_Coupon::__isset( string $key )
Magic __isset method for backwards compatibility. Legacy properties which could be accessed directly in the past.
Description Description
Parameters Parameters
- $key
-
(Required)
Return Return
(bool)
Source Source
File: includes/legacy/class-wc-legacy-coupon.php
public function __isset( $key ) { $legacy_keys = array( 'id', 'exists', 'coupon_custom_fields', 'type', 'discount_type', 'amount', 'coupon_amount', 'code', 'individual_use', 'product_ids', 'exclude_product_ids', 'usage_limit', 'usage_limit_per_user', 'limit_usage_to_x_items', 'usage_count', 'expiry_date', 'product_categories', 'exclude_product_categories', 'minimum_amount', 'maximum_amount', 'customer_email', ); if ( in_array( $key, $legacy_keys ) ) { return true; } return false; }