Automattic\WooCommerce\Internal\VariationGallery

ClassicVariationGalleryAdmin::is_product_edit_screenprivateWC 1.0

Determine if the current screen is the classic product editor.

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

Хуков нет.

Возвращает

true|false.

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

// private - только в коде основоного (родительского) класса
$result = $this->is_product_edit_screen(): bool;

Код ClassicVariationGalleryAdmin::is_product_edit_screen() WC 10.9.1

private function is_product_edit_screen(): bool {
	if ( ! function_exists( 'get_current_screen' ) ) {
		return false;
	}

	$screen = get_current_screen();

	return $screen && 'product' === $screen->id;
}