Skip to content

Commit

Permalink
Sync Checksums: Ensure is plugin active exists (#39369)
Browse files Browse the repository at this point in the history
* Ensure is_plugin_active exists
  • Loading branch information
darssen authored Sep 12, 2024
1 parent 5d37c1f commit 49715f5
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: patch
Type: fixed

Sync: Ensure is_plugin_active exists when loading Table Checksums
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,11 @@ public function __construct() {
public static function get_order_types_to_sync( $prefixed = false ) {
$types = array( 'order', 'order_refund' );

// Ensure this is available.
if ( ! function_exists( 'is_plugin_active' ) ) {
require_once ABSPATH . 'wp-admin/includes/plugin.php';
}

if ( is_plugin_active( self::WOOCOMMERCE_SUBSCRIPTIONS_PATH ) ) {
$types[] = 'subscription';
}
Expand Down

0 comments on commit 49715f5

Please sign in to comment.