Automattic\WooCommerce\Admin\API
Themes::register_routes
Register routes.
Метод класса: Themes{}
Хуков нет.
Возвращает
null. Ничего (null).
Использование
$Themes = new Themes(); $Themes->register_routes();
Код Themes::register_routes() Themes::register routes WC 10.4.3
public function register_routes() {
register_rest_route(
$this->namespace,
'/' . $this->rest_base,
array(
array(
'methods' => \WP_REST_Server::EDITABLE,
'callback' => array( $this, 'upload_theme' ),
'permission_callback' => array( $this, 'upload_theme_permissions_check' ),
'args' => $this->get_collection_params(),
),
'schema' => array( $this, 'get_public_item_schema' ),
)
);
}