Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix CYS conflict with wpcom.editor #1336

Merged
merged 4 commits into from
Oct 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions includes/class-wc-calypso-bridge-customize-store.php
Original file line number Diff line number Diff line change
Expand Up @@ -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);
}

/**
Expand Down
3 changes: 3 additions & 0 deletions readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
Loading