From 082dc9573bb7fdfbb5a6cd6b854404c68df51863 Mon Sep 17 00:00:00 2001 From: tjcafferkey Date: Thu, 4 May 2023 09:27:36 +0100 Subject: [PATCH] Remove esc_url() on self generated link to edit the Mini Cart template since it gets escaped in JS --- src/BlockTypes/MiniCart.php | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/src/BlockTypes/MiniCart.php b/src/BlockTypes/MiniCart.php index ea674438ff5..88e6c81ffab 100644 --- a/src/BlockTypes/MiniCart.php +++ b/src/BlockTypes/MiniCart.php @@ -181,14 +181,12 @@ protected function enqueue_data( array $attributes = [] ) { ); } - $template_part_edit_uri = esc_url( - add_query_arg( - array( - 'postId' => sprintf( '%s//%s', $theme_slug, 'mini-cart' ), - 'postType' => 'wp_template_part', - ), - $site_editor_uri - ) + $template_part_edit_uri = add_query_arg( + array( + 'postId' => sprintf( '%s//%s', $theme_slug, 'mini-cart' ), + 'postType' => 'wp_template_part', + ), + $site_editor_uri ); }