diff --git a/includes/class-wc-calypso-bridge-customize-store.php b/includes/class-wc-calypso-bridge-customize-store.php index 5ef011f1..efdee453 100644 --- a/includes/class-wc-calypso-bridge-customize-store.php +++ b/includes/class-wc-calypso-bridge-customize-store.php @@ -40,6 +40,14 @@ private function __construct() { add_action( 'load-site-editor.php', array( $this, 'mark_customize_store_task_as_completed_on_site_editor' ) ); } }); + + // wpcom.editor.js conflicts with CYS scripts due to double registration of the private-apis + // dequeue it on CYS pages. + add_action( 'admin_print_scripts', function() { + if ( isset( $_GET['path'] ) && str_contains( wp_unslash( $_GET['path'] ), '/customize-store/' ) ) { // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized + wp_dequeue_script( 'wpcom-block-editor-wpcom-editor-script' ); + } + }, 9999); } /** diff --git a/readme.txt b/readme.txt index 4b2e63c9..301d0a1a 100644 --- a/readme.txt +++ b/readme.txt @@ -22,6 +22,9 @@ This section describes how to install the plugin and get it working. == Changelog == += Unreleased = +* Fix CYS conflict with wpcom.editor #1336 + = 2.2.18 = * Fix the "Orders" menu position when using HPOS #1330 * Preconfigure product measurement units #1309