WC_REST_Coupons_V2_Controller::get_object()protectedWC 3.0.0

Get object.

Method of the class: WC_REST_Coupons_V2_Controller{}

No Hooks.

Return

WC_Data.

Usage

// protected - for code of main (parent) or child class
$result = $this->get_object( $id );
$id(int) (required)
Object ID.

Changelog

Since 3.0.0 Introduced.

WC_REST_Coupons_V2_Controller::get_object() code WC 8.7.0

protected function get_object( $id ) {
	return new WC_Coupon( $id );
}