Skip to content

Commit

Permalink
jetpack-mu-wpcom: fix undefined is_plugin_active fatal on wpcom (#29158)
Browse files Browse the repository at this point in the history
  • Loading branch information
samiff authored Feb 27, 2023
1 parent a80af64 commit 5bceb98
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: patch
Type: fixed

Fix undefined is_plugin_active fatal on wpcom.
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,9 @@ public static function load_coming_soon() {
* On WoA sites, users may be using non-symlinked older versions of the FSE plugin.
* If they are, check the active version to avoid redeclaration errors.
*/
if ( ! function_exists( 'is_plugin_active' ) ) {
require_once ABSPATH . 'wp-admin/includes/plugin.php';
}
$invalid_fse_version_active = is_plugin_active( 'full-site-editing/full-site-editing-plugin.php' ) && version_compare( get_plugin_data( WP_PLUGIN_DIR . '/full-site-editing/full-site-editing-plugin.php' )['Version'], '3.56084', '<' );
if ( $invalid_fse_version_active ) {
return;
Expand Down

0 comments on commit 5bceb98

Please sign in to comment.