From 7acdcefcbd5b20b5de4efabca695eeb66601cafc Mon Sep 17 00:00:00 2001 From: Aaron Robertshaw <60436221+aaronrobertshaw@users.noreply.github.com> Date: Wed, 26 Jun 2024 16:37:59 +1000 Subject: [PATCH] Section Styles: Clean up block style variation filters --- lib/block-supports/block-style-variations.php | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/lib/block-supports/block-style-variations.php b/lib/block-supports/block-style-variations.php index 12c2453681b41..1c049f4a0fee5 100644 --- a/lib/block-supports/block-style-variations.php +++ b/lib/block-supports/block-style-variations.php @@ -274,19 +274,3 @@ function gutenberg_register_block_style_variations_from_theme_json_partials( $va } } } - -// DO NOT BACKPORT TO CORE. -// To be removed when core has backported this PR. -if ( function_exists( 'wp_resolve_block_style_variations_from_styles_registry' ) ) { - remove_filter( 'wp_theme_json_data_theme', 'wp_resolve_block_style_variations_from_styles_registry' ); -} -if ( function_exists( 'wp_resolve_block_style_variations_from_primary_theme_json' ) ) { - remove_filter( 'wp_theme_json_data_theme', 'wp_resolve_block_style_variations_from_primary_theme_json' ); -} -if ( function_exists( 'wp_resolve_block_style_variations_from_theme_json_partials' ) ) { - remove_filter( 'wp_theme_json_data_theme', 'wp_resolve_block_style_variations_from_theme_json_partials' ); -} -if ( function_exists( 'wp_resolve_block_style_variations_from_theme_style_variation' ) ) { - remove_filter( 'wp_theme_json_data_user', 'wp_resolve_block_style_variations_from_theme_style_variation' ); -} -// END OF DO NOT BACKPORT TO CORE.