diff --git a/woocommerce.php b/woocommerce.php index b760bca76b5..5981ee42003 100644 --- a/woocommerce.php +++ b/woocommerce.php @@ -173,7 +173,7 @@ final class WooCommerce { case 'ajax' : return defined( 'DOING_AJAX' ); case 'frontend' : - return ! is_admin() || defined( 'DOING_AJAX' ); + return ( ! is_admin() || defined( 'DOING_AJAX' ) ) && ! defined( 'DOING_CRON' ); } }