WC_Coupon::set_used_by()
Set which users have used this coupon.
Method of the class: WC_Coupon{}
No Hooks.
Return
null
. Nothing (null).
Usage
$WC_Coupon = new WC_Coupon(); $WC_Coupon->set_used_by( $used_by );
- $used_by(array) (required)
- List of user IDs.
Changelog
Since 3.0.0 | Introduced. |
WC_Coupon::set_used_by() WC Coupon::set used by code WC 9.4.2
public function set_used_by( $used_by ) { $this->set_prop( 'used_by', array_filter( $used_by ) ); }