Automattic\WooCommerce\StoreApi

Authentication::allowed_cors_headers()publicWC 1.0

Add allowed cors headers for store API headers.

Метод класса: Authentication{}

Хуков нет.

Возвращает

Массив.

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

$Authentication = new Authentication();
$Authentication->allowed_cors_headers( $allowed_headers );
$allowed_headers(массив) (обязательный)
Allowed headers.

Код Authentication::allowed_cors_headers() WC 9.8.4

public function allowed_cors_headers( $allowed_headers ) {
	$allowed_headers[] = 'Cart-Token';
	$allowed_headers[] = 'Nonce';
	return $allowed_headers;
}