WC_Order_Refund::__get( string $key )
Magic __get method for backwards compatibility.
Description Description
Parameters Parameters
- $key
-
(Required) Value to get.
Return Return
(mixed)
Source Source
File: includes/class-wc-order-refund.php
public function __get( $key ) { wc_doing_it_wrong( $key, 'Refund properties should not be accessed directly.', '3.0' ); /** * Maps legacy vars to new getters. */ if ( 'reason' === $key ) { return $this->get_reason(); } elseif ( 'refund_amount' === $key ) { return $this->get_amount(); } return parent::__get( $key ); }