diff --git a/src/wp-admin/menu.php b/src/wp-admin/menu.php
index 94f479fb8c..e9bf0a9637 100644
a
|
b
|
if ( wp_is_block_template_theme() ) { |
217 | 217 | // Hide Customize link on block themes unless a plugin or theme is using |
218 | 218 | // customize_register to add a setting. |
219 | 219 | if ( ! wp_is_block_template_theme() || has_action( 'customize_register' ) ) { |
220 | | $customize_url = add_query_arg( 'return', urlencode( remove_query_arg( wp_removable_query_args(), wp_unslash( $_SERVER['REQUEST_URI'] ) ) ), 'customize.php' ); |
221 | | $submenu['themes.php'][7] = array( __( 'Customize' ), 'customize', esc_url( $customize_url ), '', 'hide-if-no-customize' ); |
| 220 | $customize_url = add_query_arg( 'return', urlencode( remove_query_arg( wp_removable_query_args(), wp_unslash( $_SERVER['REQUEST_URI'] ) ) ), 'customize.php' ); |
| 221 | $position = wp_is_block_template_theme() ? 7 : 6; |
| 222 | |
| 223 | $submenu['themes.php'][ $position ] = array( __( 'Customize' ), 'customize', esc_url( $customize_url ), '', 'hide-if-no-customize' ); |
222 | 224 | } |
223 | 225 | |
224 | 226 | if ( current_theme_supports( 'menus' ) || current_theme_supports( 'widgets' ) ) { |