From 650dbfa3754087ce99f76fc9010a169f2f4866d5 Mon Sep 17 00:00:00 2001 From: "Dion Hulse (dd32)" Date: Wed, 24 Jun 2020 13:10:41 +1000 Subject: [PATCH 1/2] Use a more specific matching pattern to only affect the `", $src_esc ), + sprintf( "", esc_attr( $handle ), $src_esc ), + $tag + ); return $tag; } - add_filter( 'script_loader_tag', 'gutenberg_change_script_tag', 10, 2 ); + add_filter( 'script_loader_tag', 'gutenberg_change_script_tag', 1, 3 ); } From 620089d9fb87a166b7909cf4a6e71b79b36303dd Mon Sep 17 00:00:00 2001 From: "Dion Hulse (dd32)" Date: Wed, 24 Jun 2020 13:14:21 +1000 Subject: [PATCH 2/2] Rename the variable --- lib/block-directory.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/block-directory.php b/lib/block-directory.php index 4f6a645107214..f1956f8bfbe83 100644 --- a/lib/block-directory.php +++ b/lib/block-directory.php @@ -24,18 +24,18 @@ function gutenberg_enqueue_block_editor_assets_block_directory() { * * @param string $tag The `", $src_esc ), - sprintf( "", esc_attr( $handle ), $src_esc ), + sprintf( "", $esc_src ), + sprintf( "", esc_attr( $handle ), $esc_src ), $tag );