From e6f2126b119f9983298d39ae5566d2cfa45eeeb5 Mon Sep 17 00:00:00 2001 From: Jon Brown Date: Mon, 5 Mar 2018 11:08:40 -1000 Subject: [PATCH] opps... not DRY Photon check should probably should be abstracted, but this works for now --- includes/class-wc-regenerate-images.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wc-regenerate-images.php b/includes/class-wc-regenerate-images.php index 766f91898e6..5ea380a7cbe 100644 --- a/includes/class-wc-regenerate-images.php +++ b/includes/class-wc-regenerate-images.php @@ -84,7 +84,7 @@ class WC_Regenerate_Images { // See if the image size has changed from our settings. if ( ! self::image_size_matches_settings( $data, $size ) ) { // If Photon is running we can just return false and let Jetpack handle regeneration. - if ( class_exists( 'Jetpack' ) && Jetpack::is_module_active( 'photon' ) ) { + if ( method_exists('Jetpack', 'is_module_active') && Jetpack::is_module_active( 'photon' ) ) { return false; } else { // If we get here, Jetpack is not running and we don't have the correct image sized stored. Try to return closest match.