WC_Order_Refund::get_refund
Deprecated since 3.0. It is no longer supported and may be removed in future releases. It is recommended to replace this function with the same one.
Gets an refund from the database.
Method of the class: WC_Order_Refund{}
No Hooks.
Returns
true|false
.
Usage
$WC_Order_Refund = new WC_Order_Refund(); $WC_Order_Refund->get_refund( $id );
- $id(int)
- .
Default: 0)
Changelog
Deprecated since | 3.0 |
WC_Order_Refund::get_refund() WC Order Refund::get refund code WC 9.9.4
public function get_refund( $id = 0 ) { wc_deprecated_function( 'get_refund', '3.0', 'read' ); if ( ! $id ) { return false; } $result = wc_get_order( $id ); if ( $result ) { $this->populate( $result ); return true; } return false; }