HEX
Server: LiteSpeed
System: Linux cluster02.load-balancer.x2.network 4.18.0-553.51.1.lve.1.el8.x86_64 #1 SMP Wed May 14 14:34:57 UTC 2025 x86_64
User: kbdhpghp (1098)
PHP: 8.2.29
Disabled: NONE
Upload Files
File: /home/kbdhpghp/www/aqualander/wp-content/plugins/woocommerce-mercadopago/src/Startup.php
<?php

namespace MercadoPago\Woocommerce;

if (!defined('ABSPATH')) {
    exit;
}

class Startup
{
    /**
     * Verify if plugin has its packages and autoloader file
     *
     * @return bool
     */
    public static function available(): bool
    {
        return self::haveAutoload();
    }

    /**
     * Check's if autoload file is present and is readable
     *
     * @return bool
     */
    protected static function haveAutoload(): bool
    {
        $file = dirname(__DIR__) . '/vendor/autoload.php';

        if (is_file($file) && is_readable($file)) {
            return true;
        }

        add_action('admin_notices', fn() => $file && include __DIR__ . '/../templates/admin/notices/miss-autoload.php');
        return false;
    }
}