is_plugin_active( 'amazon-s3-and-cloudfront-pro/amazon-s3-and-cloudfront-pro.php' ) ) { // Don't load if pro plugin installed return; } if ( ! $as3cf_compat_check->is_compatible() ) { return; } global $as3cf; $abspath = dirname( __FILE__ ); // Autoloader. require_once $abspath . '/wp-offload-media-autoloader.php'; require_once $abspath . '/include/functions.php'; require_once $abspath . '/classes/as3cf-utils.php'; require_once $abspath . '/classes/as3cf-error.php'; require_once $abspath . '/classes/as3cf-filter.php'; require_once $abspath . '/classes/filters/as3cf-local-to-s3.php'; require_once $abspath . '/classes/filters/as3cf-s3-to-local.php'; require_once $abspath . '/classes/as3cf-notices.php'; require_once $abspath . '/classes/as3cf-plugin-base.php'; require_once $abspath . '/classes/as3cf-plugin-compatibility.php'; require_once $abspath . '/classes/amazon-s3-and-cloudfront.php'; new WP_Offload_Media_Autoloader( 'WP_Offload_Media', $abspath ); $as3cf = new Amazon_S3_And_CloudFront( __FILE__ ); do_action( 'as3cf_init', $as3cf ); } add_action( 'init', 'as3cf_init' ); // If AWS still active need to be around to satisfy addon version checks until upgraded. add_action( 'aws_init', 'as3cf_init', 11 );