WordPress как на ладони
Недорогой хостинг для сайтов на WordPress: wordpress.jino.ru
функция не описана

WC_Helper::get_local_woo_themes() public WC 1.0

Get locally installed Woo themes.

Это метод класса: WC_Helper{}

Хуков нет.

Возвращает

Null. Ничего.

Использование

$result = WC_Helper::get_local_woo_themes();

Код WC_Helper::get_local_woo_themes() WC 4.5.2

woocommerce/includes/admin/helper/class-wc-helper.php
<?php
public static function get_local_woo_themes() {
	$themes     = wp_get_themes();
	$woo_themes = array();

	foreach ( $themes as $theme ) {
		$header = $theme->get( 'Woo' );

		// Backwards compatibility for theme_info.txt.
		if ( ! $header ) {
			$txt = $theme->get_stylesheet_directory() . '/theme_info.txt';
			if ( is_readable( $txt ) ) {
				$txt = file_get_contents( $txt );
				$txt = preg_split( '#\s#', $txt );
				if ( count( $txt ) >= 2 ) {
					$header = sprintf( '%d:%s', $txt[0], $txt[1] );
				}
			}
		}

		if ( empty( $header ) ) {
			continue;
		}

		list( $product_id, $file_id ) = explode( ':', $header );
		if ( empty( $product_id ) || empty( $file_id ) ) {
			continue;
		}

		$data = array(
			'Name'        => $theme->get( 'Name' ),
			'Version'     => $theme->get( 'Version' ),
			'Woo'         => $header,

			'_filename'   => $theme->get_stylesheet() . '/style.css',
			'_stylesheet' => $theme->get_stylesheet(),
			'_product_id' => absint( $product_id ),
			'_file_id'    => $file_id,
			'_type'       => 'theme',
		);

		$woo_themes[ $data['_filename'] ] = $data;
	}

	return $woo_themes;
}