WC_REST_Data_Currencies_Controller::get_current_item()
Return information for the current site currency.
Метод класса: WC_REST_Data_Currencies_Controller{}
Хуков нет.
Возвращает
WP_Error|WP_REST_Response
.
Использование
$WC_REST_Data_Currencies_Controller = new WC_REST_Data_Currencies_Controller(); $WC_REST_Data_Currencies_Controller->get_current_item( $request );
- $request(WP_REST_Request) (обязательный)
- Request data.
Код WC_REST_Data_Currencies_Controller::get_current_item() WC REST Data Currencies Controller::get current item WC 9.3.3
public function get_current_item( $request ) { $currency = get_option( 'woocommerce_currency' ); return $this->prepare_item_for_response( $this->get_currency( $currency, $request ), $request ); }