| Server IP : 104.21.21.239 / Your IP : 216.73.216.25 Web Server : Apache/2.4.68 (Amazon Linux) OpenSSL/3.5.5 System : Linux ip-172-31-69-123.ec2.internal 6.1.176-223.369.amzn2023.x86_64 #1 SMP PREEMPT_DYNAMIC Fri Jul 24 13:34:27 UTC 2026 x86_64 User : ec2-user ( 1000) PHP Version : 8.4.23 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /home/home2/domains/new.davlermedia.com/wp-content/plugins/wp-rocket/inc/Engine/Debug/ |
Upload File : |
<?php
namespace WP_Rocket\Engine\Debug;
use WP_Rocket\Admin\Options_Data;
/**
* Resolver.
*/
class Resolver {
/**
* Array of WP Rocket Options.
*
* @var array
*/
private $options_services = [
'remove_unused_css' => [
'service' => 'rucss_debug_subscriber',
'class' => 'WP_Rocket\Engine\Debug\RUCSS\Subscriber',
],
];
/**
* Debug options instance.
*
* @var Options_Data
*/
private $options;
/**
* Instantiate the class.
*
* @param Options_Data $options Options instance.
*/
public function __construct( Options_Data $options ) {
$this->options = $options;
}
/**
* Ships an array of available services.
*
* @return array Array of services.
*/
public function get_services(): array {
$set_services = [];
if ( empty( $this->options_services ) ) {
return [];
}
foreach ( $this->options_services as $option => $services ) {
if ( ! (bool) $this->options->get( $option, 0 ) ) {
continue;
}
$set_services[] = $services;
}
return $set_services;
}
}