WordPress at Your Fingertips
function is not described

WC_Order_Refund::__get() public WC 1.0

Magic __get method for backwards compatibility.

{} It's a method of the class: WC_Order_Refund{}

No Hooks.

Return

Mixed.

Usage

$WC_Order_Refund = new WC_Order_Refund();
$WC_Order_Refund->__get( $key );
$key(string) (required)
Value to get.

Code of WC_Order_Refund::__get() WC 5.8.0

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 );
}