• File: functions.php
  • Full Path: /home/matthif/www/wp-content/plugins/wordpress-seo/src/functions.php
  • Date Modified: 02/24/2024 11:29 PM
  • File size: 697 bytes
  • MIME-type: text/x-php
  • Charset: utf-8
<?php
/**
 * WPSEO plugin file.
 *
 * @package WPSEO\Internals
 */

if ( ! defined'WPSEO_VERSION' ) ) {
    
header'Status: 403 Forbidden' );
    
header'HTTP/1.1 403 Forbidden' );
    exit();
}

use 
Yoast\WP\SEO\Main;

if ( 
is_dirWPSEO_PATH YOAST_VENDOR_PREFIX_DIRECTORY ) ) {
    require_once 
WPSEO_PATH YOAST_VENDOR_PREFIX_DIRECTORY '/guzzlehttp/guzzle/src/functions.php';
}

/**
 * Retrieves the main instance.
 *
 * @phpcs:disable WordPress.NamingConventions -- Should probably be renamed, but leave for now.
 *
 * @return Main The main instance.
 */
function YoastSEO() {
    
// phpcs:enable

    
static $main;

    if ( 
$main === null ) {
        
$main = new Main();
        
$main->load();
    }

    return 
$main;
}