WC_REST_Data_Currencies_Controller::get_current_item()publicWC 1.0

Return information for the current site currency.

Method of the class: WC_REST_Data_Currencies_Controller{}

No Hooks.

Return

WP_Error|WP_REST_Response.

Usage

$WC_REST_Data_Currencies_Controller = new WC_REST_Data_Currencies_Controller();
$WC_REST_Data_Currencies_Controller->get_current_item( $request );
$request(WP_REST_Request) (required)
Request data.

WC_REST_Data_Currencies_Controller::get_current_item() code WC 8.9.0

public function get_current_item( $request ) {
	$currency = get_option( 'woocommerce_currency' );
	return $this->prepare_item_for_response( $this->get_currency( $currency, $request ), $request );
}