-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Blocks: remove gutenberg refs in PHP files #51978
Conversation
…ible to avoid conflicts with Core.
@@ -341,7 +341,11 @@ function block_core_navigation_get_fallback_blocks() { | |||
// If `core/page-list` is not registered then return empty blocks. | |||
$fallback_blocks = $registry->is_registered( 'core/page-list' ) ? $page_list_fallback : array(); | |||
|
|||
$navigation_post = Gutenberg_Navigation_Fallback::get_fallback(); | |||
if ( class_exists( 'WP_Navigation_Fallback' ) ) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure if I this should be
if ( defined( 'IS_GUTENBERG_PLUGIN' ) && IS_GUTENBERG_PLUGIN ) {
Same effect, just convention?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd go with the class_exists
check, since the compat layer changes over time (and is thus not directly equivalent to the presence of the plugin).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code LGTM! Testing locally everything is working well.
* Removes references to execution code referencing gutenberg where possible to avoid conflicts with Core. * Added deprecated notices * Removed `gutenberg_` for `IS_GUTENBERG_PLUGIN` only method
Cherry-picked to the |
@ramonjd @tellthemachines Should this also go into GB 16.1? |
It probably should have I think. I can't see it the changes in the branch or in the commit history. |
I think it's also missing 40aa280 |
* Removes references to execution code referencing gutenberg where possible to avoid conflicts with Core. * Added deprecated notices * Removed `gutenberg_` for `IS_GUTENBERG_PLUGIN` only method
What?
Removes references to execution code referencing gutenberg where possible.
Why?
To avoid conflicts with Core
How?
Keyboard!
Testing Instructions
Tests should pass.
Editor should load.