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

wc_prepare_attachment_for_js() WC 1.0

Prepare attachment for JavaScript.

Хуков нет.

Возвращает

Массив.

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

wc_prepare_attachment_for_js( $response );
$response(массив) (обязательный)
JS version of a attachment post object.

Код wc_prepare_attachment_for_js() WC 4.5.2

woocommerce/includes/wc-product-functions.php
<?php
function wc_prepare_attachment_for_js( $response ) {

	if ( isset( $response['url'] ) && strstr( $response['url'], 'woocommerce_uploads/' ) ) {
		$response['full']['url'] = wc_placeholder_img_src();
		if ( isset( $response['sizes'] ) ) {
			foreach ( $response['sizes'] as $size => $value ) {
				$response['sizes'][ $size ]['url'] = wc_placeholder_img_src();
			}
		}
	}

	return $response;
}