update patch 1
This commit is contained in:
@@ -40,10 +40,12 @@ class ConfigDataCollector extends DataCollector implements LateDataCollectorInte
|
||||
$eom = \DateTimeImmutable::createFromFormat('d/m/Y', '01/'.Kernel::END_OF_MAINTENANCE);
|
||||
$eol = \DateTimeImmutable::createFromFormat('d/m/Y', '01/'.Kernel::END_OF_LIFE);
|
||||
|
||||
$xdebugMode = getenv('XDEBUG_MODE') ?: \ini_get('xdebug.mode');
|
||||
|
||||
$this->data = [
|
||||
'token' => $response->headers->get('X-Debug-Token'),
|
||||
'symfony_version' => Kernel::VERSION,
|
||||
'symfony_minor_version' => sprintf('%s.%s', Kernel::MAJOR_VERSION, Kernel::MINOR_VERSION),
|
||||
'symfony_minor_version' => \sprintf('%s.%s', Kernel::MAJOR_VERSION, Kernel::MINOR_VERSION),
|
||||
'symfony_lts' => 4 === Kernel::MINOR_VERSION,
|
||||
'symfony_state' => $this->determineSymfonyState(),
|
||||
'symfony_eom' => $eom->format('F Y'),
|
||||
@@ -55,8 +57,11 @@ class ConfigDataCollector extends DataCollector implements LateDataCollectorInte
|
||||
'php_intl_locale' => class_exists(\Locale::class, false) && \Locale::getDefault() ? \Locale::getDefault() : 'n/a',
|
||||
'php_timezone' => date_default_timezone_get(),
|
||||
'xdebug_enabled' => \extension_loaded('xdebug'),
|
||||
'xdebug_status' => \extension_loaded('xdebug') ? ($xdebugMode && $xdebugMode !== 'off' ? 'Enabled (' . $xdebugMode . ')' : 'Not enabled') : 'Not installed',
|
||||
'apcu_enabled' => \extension_loaded('apcu') && filter_var(\ini_get('apc.enabled'), \FILTER_VALIDATE_BOOL),
|
||||
'apcu_status' => \extension_loaded('apcu') ? (filter_var(\ini_get('apc.enabled'), FILTER_VALIDATE_BOOLEAN) ? 'Enabled' : 'Not enabled') : 'Not installed',
|
||||
'zend_opcache_enabled' => \extension_loaded('Zend OPcache') && filter_var(\ini_get('opcache.enable'), \FILTER_VALIDATE_BOOL),
|
||||
'zend_opcache_status' => \extension_loaded('Zend OPcache') ? (filter_var(\ini_get('opcache.enable'), FILTER_VALIDATE_BOOLEAN) ? 'Enabled' : 'Not enabled') : 'Not installed',
|
||||
'bundles' => [],
|
||||
'sapi_name' => \PHP_SAPI,
|
||||
];
|
||||
@@ -192,6 +197,11 @@ class ConfigDataCollector extends DataCollector implements LateDataCollectorInte
|
||||
return $this->data['xdebug_enabled'];
|
||||
}
|
||||
|
||||
public function getXdebugStatus(): string
|
||||
{
|
||||
return $this->data['xdebug_status'];
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns true if the function xdebug_info is available.
|
||||
*/
|
||||
@@ -208,6 +218,11 @@ class ConfigDataCollector extends DataCollector implements LateDataCollectorInte
|
||||
return $this->data['apcu_enabled'];
|
||||
}
|
||||
|
||||
public function getApcuStatus(): string
|
||||
{
|
||||
return $this->data['apcu_status'];
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns true if Zend OPcache is enabled.
|
||||
*/
|
||||
@@ -216,6 +231,11 @@ class ConfigDataCollector extends DataCollector implements LateDataCollectorInte
|
||||
return $this->data['zend_opcache_enabled'];
|
||||
}
|
||||
|
||||
public function getZendOpcacheStatus(): string
|
||||
{
|
||||
return $this->data['zend_opcache_status'];
|
||||
}
|
||||
|
||||
public function getBundles(): array|Data
|
||||
{
|
||||
return $this->data['bundles'];
|
||||
|
||||
Reference in New Issue
Block a user