Update PageController.php (https://github.com/woocommerce/woocommerce-admin/pull/7855)
* Update PageController.php * Create fix-7758 * Minor fixes
This commit is contained in:
parent
2e1473a25e
commit
ebcd4d9682
|
@ -0,0 +1,6 @@
|
||||||
|
Significance: minor
|
||||||
|
Type: Fix
|
||||||
|
|
||||||
|
Fix an issue with the code that makes use of an invalid parameter
|
||||||
|
with a PHP function. The use of this invalid parameter causes PHP 8 to
|
||||||
|
throw a Fatal Error. #7855
|
|
@ -356,7 +356,7 @@ class PageController {
|
||||||
|
|
||||||
// Disable embed on the block editor.
|
// Disable embed on the block editor.
|
||||||
$current_screen = did_action( 'current_screen' ) ? get_current_screen() : false;
|
$current_screen = did_action( 'current_screen' ) ? get_current_screen() : false;
|
||||||
if ( method_exists( $current_screen, 'is_block_editor' ) && $current_screen->is_block_editor() ) {
|
if ( ! empty( $current_screen ) && method_exists( $current_screen, 'is_block_editor' ) && $current_screen->is_block_editor() ) {
|
||||||
$is_connected_page = false;
|
$is_connected_page = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue