Merged in feature/MAW-855-import-code-into-aws (pull request #2)
code import from pantheon * code import from pantheon
This commit is contained in:
@@ -5,12 +5,7 @@
|
||||
* @package Yoast\WP\SEO\Premium
|
||||
*/
|
||||
|
||||
if ( ! defined( 'WPSEO_PREMIUM_VERSION' ) ) {
|
||||
header( 'Status: 403 Forbidden' );
|
||||
header( 'HTTP/1.1 403 Forbidden' );
|
||||
exit();
|
||||
}
|
||||
|
||||
use Yoast\WP\SEO\Premium\Addon_Installer;
|
||||
use Yoast\WP\SEO\Premium\Main;
|
||||
|
||||
/**
|
||||
@@ -25,7 +20,8 @@ function YoastSEOPremium() {
|
||||
|
||||
static $main;
|
||||
if ( did_action( 'wpseo_loaded' ) ) {
|
||||
if ( $main === null ) {
|
||||
$should_load = Addon_Installer::is_yoast_seo_up_to_date();
|
||||
if ( $main === null && $should_load ) {
|
||||
// Ensure free is loaded as loading premium will fail without it.
|
||||
YoastSEO();
|
||||
$main = new Main();
|
||||
|
||||
Reference in New Issue
Block a user